feat(http): switch to new parser version (#7063)

This commit is contained in:
Alejandro 2024-08-21 03:08:45 -04:00 committed by GitHub
parent 6699eae8ba
commit 0fd6d32482
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 39 additions and 38 deletions

View file

@ -9,9 +9,20 @@
((xml_body) @injection.content
(#set! injection.language "xml"))
((graphql_body) @injection.content
((graphql_data) @injection.content
(#set! injection.language "graphql"))
; Lua scripting
((script_variable) @injection.content
(#set! injection.language "lua"))
; Script (default to javascript)
((script) @injection.content
(#offset! @injection.content 0 2 0 -2)
(#set! injection.language "javascript"))
; Script with other languages
((comment
name: (_) @_name
(#eq? @_name "lang")
value: (_) @injection.language)
.
(_
(script) @injection.content
(#offset! @injection.content 0 2 0 -2)))