mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-13 08:50:11 -04:00
Add PHP heredoc and nowdoc injections (#4866)
This commit is contained in:
parent
78b54eb7f6
commit
246f4cc20c
1 changed files with 13 additions and 3 deletions
|
|
@ -1,9 +1,19 @@
|
||||||
((text) @injection.content
|
((text) @injection.content
|
||||||
(#set! injection.language "html")
|
(#set! injection.language "html")
|
||||||
(#set! injection.combined))
|
(#set! injection.combined))
|
||||||
|
|
||||||
((comment) @injection.content
|
((comment) @injection.content
|
||||||
(#set! injection.language "phpdoc"))
|
(#set! injection.language "phpdoc"))
|
||||||
|
|
||||||
|
(heredoc
|
||||||
|
(heredoc_body) @injection.content
|
||||||
|
(heredoc_end) @injection.language
|
||||||
|
(#downcase! @injection.language))
|
||||||
|
|
||||||
|
(nowdoc
|
||||||
|
(nowdoc_body) @injection.content
|
||||||
|
(heredoc_end) @injection.language
|
||||||
|
(#downcase! @injection.language))
|
||||||
|
|
||||||
;; regex
|
;; regex
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue