3 ms·
For the same reason people use JavaScript in the back-end (Node.JS) — Code Reuse If you are a Rust developer and need to create some code for the frontend of a
by guessmyname 9y ago
For the same reason people use JavaScript in the back-end (Node.JS) — Code Reuse
If you are a Rust developer and need to create some code for the frontend of a web service, this solution allows you to keep your confidence in the language that you are already used to use (Rust in this example) instead of having to worry about the ambiguity of the JavaScript language.
- tomjakubowski 9y agoI would expect WebAssembly to be used to implement things like video codecs that aren't provided by the host browser, not for typical frontend code. I'm happy to be proven wrong by ambitious WebAssemblers, though!
- yeukhon 9y agoBut don’t forget you still have css and html in your frontend stack. Javascript libraries need to be written in Rust so we can mainpluate the DOM (which needs support with browser API).
- rickycook 9y agoi think that’s probably right, but sharing things like form/api validation so that you can fairly reliably say that there’s unlikely to be backend validation errors (other than DB) would be nice... and it doesn’t require high throughput at all