-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LF Code Syntax Highlighting for Handbook #5
Comments
The syntax highlighting in VS Code is a lot more advanced than what is possible with prismjs, which is really just based on regular expression matching. Is there a way to leverage artifacts of the actual VS Code extension, like its TextMate grammar? |
I found this, but it says it's not ready for production use. |
So, yeah, maybe Prism is the way to go for now? Let me also tag @petervdonovan in case he has ideas about this. |
In the spirit of staying DRY, maybe we could use the grammar file interpreter that is used in VS Code? That, combined with the non-declarative highlighting code, should be able to precisely match the highlight experience for VS Code users. There are some problems with this. Apparently, "cross - grammar injections are currently not supported," but we need cross-grammar injections to highlight |
This should be addressed by #11. |
Improvement Idea: Implementing Code Syntax Highlighting for Lingua Franca Code Snippets using PrismJS
Why: VS Code already implements Code Syntax Highlighting for .lf files. Remark-PrismJS is the standard Gatsby Plugin used to highlight code on Gatsby websites, and it's possible to create a custom language that Prism can process for code snippets
The text was updated successfully, but these errors were encountered: