tree-sitter-rescript icon indicating copy to clipboard operation
tree-sitter-rescript copied to clipboard

Convert tree-sitter to Lezer trees for CodeMirror 6 support

Open ryyppy opened this issue 2 years ago • 2 comments

I always wanted to upgrade the ReScript online playground to the newest CodeMirror version, but CM transitioned from regex based language parsers to a more sophisticated parser system called Lezer.

If the tree-sitter is stable enough to reflect all parts of the language, I thought it would be interesting to try to use the tree-sitter parser as a shim until I figured out how to proceed writing a dedicated Lezer parser.

https://discuss.codemirror.net/t/mapping-tree-sitter-trees-to-lezer-trees/2362

ryyppy avatar Feb 03 '23 09:02 ryyppy

Yes, the grammar is stable enough and covers most quirky cases, so anyone can try to port to Lezer.

With this issue, are we trying to summon someone to do this? :)

nkrkv avatar Feb 03 '23 15:02 nkrkv

Yeah, I kinda put this note here in case someone feels inspired to try it.

ryyppy avatar Feb 05 '23 18:02 ryyppy