aboutsummaryrefslogtreecommitdiff
path: root/runtime/queries/javascript
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/queries/javascript')
-rw-r--r--runtime/queries/javascript/injections.scm12
1 files changed, 10 insertions, 2 deletions
diff --git a/runtime/queries/javascript/injections.scm b/runtime/queries/javascript/injections.scm
index e8429111..af3aef10 100644
--- a/runtime/queries/javascript/injections.scm
+++ b/runtime/queries/javascript/injections.scm
@@ -22,7 +22,15 @@
((regex_pattern) @injection.content
(#set! injection.language "regex"))
- ; Parse JSDoc annotations in comments
+; Parse JSDoc annotations in multiline comments
((comment) @injection.content
- (#set! injection.language "jsdoc"))
+ (#set! injection.language "jsdoc")
+ (#match? @injection.content "^/\\*+"))
+
+; Parse general tags in single line comments
+
+((comment) @injection.content
+ (#set! injection.language "comment")
+ (#match? @injection.content "^//"))
+