VS Code Wasp language extension
This is a Visual Studio Code language extension for wasp language!
For now, only feature is syntax highlighting of .wasp files.
Development (for contributors)
Grammar is defined in
syntaxes/wasp.tmLanguage.yaml, and you do most of the changes there.
VSCode needs .json, not .yaml -> use
npm run build to generate .json from .yaml.
package.json is also important -> besides general settings, we also define embedded languages and extension dependencies there.
- Open root dir of this project with VSCode.
- Run F5 -> this will start another, "testing" window with extension loaded and working.
- In "testing" window: open some .wasp file to see how extension works.
- Modify extension source with new changes (most likely
npm run build to regenerate .json.
- In "testing" window: run "Reload Window" command to load updated version of extension.
- In "testing" window: while inspecting .wasp file to see how extension works, you can
run "Developer: Inspect Editor Tokens and Scopes" command to get a popup for each token showing
how it got clasified/scoped by extension -> this is great for figuring out if extension does what it should do,
which is at the end, applying correct scopes.
- Repeat step 4.
Make sure you have
npm -g install vsce.
Next, make sure you are logged in with the publisher.
If you are not logged in yet, you can log in with
vsce login wasp-lang.
To package the extension into a .vsix file, run
To package and then publish the extension, run