In this repository, I am sharing Circom syntax highlighting for Sublime Text using the Monokai theme. This highlighting makes it easier to distinguish different types of variables throughout the code, which I find especially useful when implementing complex circuits.
-
tm_***: template variables -
st_***: statement signals -
wt_***: witness signals -
cp_***: components
This guide walks you through creating and activating a custom syntax definition for Sublime Text, assuming a completely fresh install.
- Open Sublime and go to:
Preferences > Browse Packages…
This will open the Packages/ folder in your file explorer. Create/use User/ directory.
- Copy Circom syntax highlighting files
Copy Circom.sublime-syntax and Monokai.sublime-color-scheme file into the User/ folder. If you open another Circom file in Monokai theme, you will be able to see the new syntax coloring.
I’ll try to add syntax highlighting support for other themes as well. Contributions via pull requests are also welcome.
