3 ms·
Can someone explain why I would want Web Assembly versus just writing in another language? Serious question: I feel like I am missing the use case for somethin
by outside1234 6y ago
Can someone explain why I would want Web Assembly versus just writing in another language?
Serious question: I feel like I am missing the use case for something like this - is it primarily useful for multi-tenant scenarios where you want to sandbox the workload or ??
- DonHopkins 6y agoIt's great if you're already using TypeScript for the server and browser (non-WebAssembly) parts of your system. That way you can harmoniously share some of the same code and data structures.
- CyberDildonics 6y agoWebasm is something you compile to, not write in. It can be run in a web browser at near native speeds. I don't understand the rest of your question or what your question marks allude to.
- outside1234 6y agoSo is the use case that I want to write code for the Browser but in an alternative language (say, in Rust)?
- jakelazaroff 6y agoThere’s another post on the front page right now about how Shopify uses wasm outside of the browser: https://news.ycombinator.com/item?id=25476605 https://news.ycombinator.com/item?id=25476605
- kbumsik 6y agoIt can be used when you just want native, low-level WASM features. It is often better when you don't want complex WASM interoperability interfaces of other languages. This help your code keep clean. Its minimal runtime can be run outside of browser easily. Even Rust requires complex interfaces, requires big runtime binaries to run on WASM, and it sometimes is not portable that it can run only on browsers.