Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'runtime/queries/javascript/locals.scm')
| -rw-r--r-- | runtime/queries/javascript/locals.scm | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/runtime/queries/javascript/locals.scm b/runtime/queries/javascript/locals.scm index 2a40b372..5d680acf 100644 --- a/runtime/queries/javascript/locals.scm +++ b/runtime/queries/javascript/locals.scm @@ -1,3 +1,23 @@ -; See runtime/queries/ecma/README.md for more info. +; Scopes +;------- -; inherits: _javascript,ecma +[ + (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 |