diff options
Diffstat (limited to 'runtime/queries/javascript/locals.scm')
-rw-r--r-- | runtime/queries/javascript/locals.scm | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/runtime/queries/javascript/locals.scm b/runtime/queries/javascript/locals.scm new file mode 100644 index 00000000..5d680acf --- /dev/null +++ b/runtime/queries/javascript/locals.scm @@ -0,0 +1,23 @@ +; Scopes +;------- + +[ + (statement_block) + (function) + (arrow_function) + (function_declaration) + (method_definition) +] @local.scope + +; Definitions +;------------ + +(pattern/identifier)@local.definition + +(variable_declarator + name: (identifier) @local.definition) + +; References +;------------ + +(identifier) @local.reference |