Build instructions

March 19, 2020 ยท View on GitHub

In general, {Syntax Highlighter} extension is built the same way as any other VSCode extension. {Syntax Highlighter} utilizes WebAssembly bindings to the Tree-sitter parsing library. All language parsers are therefore compiled to binary .wasm modules. This is done by postinstall hook when you call npm install as usual. See build.js script for details.

To build .wasm you'll need Emscripten SDK. Installation instructions can be found here or here. Or you can use docker. tree-sitter-cli will try to deploy trzeci/emscripten-slim image as fallback when emcc isn't found.