better mdx support
This commit is contained in:
parent
84ed8665bb
commit
d915829d01
2 changed files with 13 additions and 0 deletions
4
after/queries/markdown/highlights.scm
Normal file
4
after/queries/markdown/highlights.scm
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
;extends
|
||||||
|
|
||||||
|
((inline) @_inline (#lua-match? @_inline "^%s*import")) @nospell
|
||||||
|
((inline) @_inline (#lua-match? @_inline "^%s*export")) @nospell
|
|
@ -1,7 +1,16 @@
|
||||||
;extends
|
;extends
|
||||||
|
|
||||||
|
; Supporting dataviewjs
|
||||||
(fenced_code_block
|
(fenced_code_block
|
||||||
((info_string) @_lang
|
((info_string) @_lang
|
||||||
(#match? @_lang "(dataviewjs)"))
|
(#match? @_lang "(dataviewjs)"))
|
||||||
(code_fence_content) @javascript
|
(code_fence_content) @javascript
|
||||||
)
|
)
|
||||||
|
|
||||||
|
; Supporting MDX
|
||||||
|
((inline) @injection.content
|
||||||
|
(#lua-match? @injection.content "^%s*import")
|
||||||
|
(#set! injection.language "typescript"))
|
||||||
|
((inline) @injection.content
|
||||||
|
(#lua-match? @injection.content "^%s*export")
|
||||||
|
(#set! injection.language "typescript"))
|
||||||
|
|
Loading…
Reference in a new issue