playground
playground copied to clipboard
zig + zls but wasm and it's in the browser 🤯🤯🤯
zls in the browser
Works pretty well in a bunch of browsers, but note the required security headers.
Installing
- Compile zls for
wasm32-wasi
and placezls.wasm
insrc
- Additionally, place
zig.tar.gz
(make sure that the name matches) from the website insrc
- If you've downloaded Zig and built from source following
ZIG_WASM.md
, you can also use this command:tar -C /path/to/zig -cz lib/std >src/zig.tar.gz
- If you've downloaded Zig and built from source following
npm install
npm run serve
Enjoy!
TODOs
- [ ] Stop using
SharedArrayBuffer
s (they're awesome but a nightmare to deploy)