syntax/json: Add comment support to the syntax highlighting (#3434)

* allow comments in json

* syntax/json: Add colon to `TODO` comments

---------

Co-authored-by: Sertonix <83883937+Sertonix@users.noreply.github.com>
This commit is contained in:
Jöran Karl
2024-08-19 22:16:42 +02:00
committed by GitHub
parent f74eb23827
commit cc195b6a96

View File

@@ -25,3 +25,15 @@ rules:
- statement: "\\\"(\\\\\"|[^\"])*\\\"[[:space:]]*:\" \"'(\\'|[^'])*'[[:space:]]*:"
- constant: "\\\\u[0-9a-fA-F]{4}|\\\\[bfnrt'\"/\\\\]"
- comment:
start: "//"
end: "$"
rules:
- todo: "(TODO|XXX|FIXME):?"
- comment:
start: "/\\*"
end: "\\*/"
rules:
- todo: "(TODO|XXX|FIXME):?"