This is an extremely basic Mosaic syntax highlighter for Visual Studio Code. It uses code and ideas from both the Prisma Visual Studio Code extension and the Felix Atom extension.
To install, simply drag the repo folder to C:\Users\username.vscode\extensions and restart Visual Studio Code.
This is not a particularly refined syntax highlighter, so there will likely be issues. I have little experience writing regexes and leaned heavily on the prior two examples for help with getting the basics right. I have also simply borrowed the numeric regex from the latter.
Notable missing features include:
- Syntax highlighting for variables.
- Syntax highlighting for user-defined records and types in declarations.
- Proper automatic closing statements for
if
anddo
blocks.
Despite that, this should at least be a good start. Improvements will be ongoing as I find time.