2 ms·
It's __doable__ but I can't yet in earnest recommend it for a serious project (outside of canvas controlled GUIs). The SharedArrayBuffer implementation require
by apatheticonion 3y ago
It's __doable__ but I can't yet in earnest recommend it for a serious project (outside of canvas controlled GUIs).
The SharedArrayBuffer implementation requires spawning the same wasm module multiple times and passing the SAB to each instance. This works but is no replacement for thread management by the module/process itself.
It also requires restrictive "Cross-Origin-Opener-Policy" and "Cross-Origin-Embedder-Policy" headers - making it largely impossible for applications with multiple subdomains (for instance apps that have their API on api.myapp.com, or assets on cdn.myapp.com). Not an easy change for an established enterprise application.
Glue code might be performant but I really just want to go
> cargo build --target wasm
and
> <script src="app.wasm" type="application/wasm"></script>