2 ms·
If you want or need to stay totally within the JavaScript ecosystem, Marijn Haverbeke (author of CodeMirror, ProseMirror, and more) created Lezer which is tree-
by dugmartin 3y ago
If you want or need to stay totally within the JavaScript ecosystem, Marijn Haverbeke (author of CodeMirror, ProseMirror, and more) created Lezer which is tree-sitter like and is grammar driven with optional external tokenizers also:
Announcement: https://marijnhaverbeke.nl/blog/lezer.html https://marijnhaverbeke.nl/blog/lezer.html
Homepage: https://lezer.codemirror.net/ https://lezer.codemirror.net/
- mdaniel 3y agohttps://lezer.codemirror.net/docs/guide/#token-specialization https://lezer.codemirror.net/docs/guide/#token-specializatio... is pretty cool, and they make use of it in the python grammar for the new "match" and "case" soft keywords: https://github.com/lezer-parser/python/blob/ead67a397f7c7cb688e36d941a32c1527d7cc409/src/python.grammar#L45 https://github.com/lezer-parser/python/blob/ead67a397f7c7cb6...