4 ms·
I don't get why people are so excited about WebAssembly, at least on the whole "replace Javascript"/"remove web bloat" aspect. Right now we have Javascript and
by oblio 10y ago
I don't get why people are so excited about WebAssembly, at least on the whole "replace Javascript"/"remove web bloat" aspect.
Right now we have Javascript and its assorted libraries, which, as bad as they are, come with the browser or at least are generally reused/cached very frequently.
People seem to fail to realize that everyone and their mother will dump their runtimes and their VMs on top of WebAssembly as soon as they will be able to. Java Applets 1, 2, ..., 100.
Yes, they will present it in a very fancy and attractive way, but fundamentally that's what will happen, cause who wants to rewrite everything for Javascript-land when they're not forced to? Competitive pressure will always push towards bloat, just look at Facebook and they Android-runtime busting app for an example.
I, for one, am looking forward to the day where, besides the 500MB of Javascript my 40 tabs are loading, I'll also load 1.5 GB of WebAssemblied formerly native runtimes.
- s369610 10y agoI doubt it will be for average brochure sites, but I have used it in two situations, one to encode a series of captured canvas frames into ogg video on the client using ffmpeg to save bandwidth on a telehealth web application, and another to embed a mobile game engine in with samples so users can interact in the browser without having to download build and run http://moaiforge.com/samples/sample-browser/player/index.html#hello-moai http://moaiforge.com/samples/sample-browser/player/index.htm...
- tromp 10y agoI'm excited at the prospect of 64-bit integer support, which will significantly speed up many applications, making even web-based proof-of-work mining feasible.
- rspeer 10y agoWait. Why would you want web-based proof-of-work mining? Does this have a legitimate purpose, or is it all about forcing unsuspecting visitors to mine Bitcoin for you?
- drchickensalad 10y agoFor things that are DOS-sensitive
- tromp 10y agoThe web page should only start the miner if the user is well informed and clicks a button to start it. Legitimate purposes include spam-proofing message boxes, as well as cryptocurrencies whose PoW is somewhat CPU friendly, such as those bottlenecked by DRAM latency.
- Someone 10y agoJavaScript got at least part of its popularity because it was the only thing that ran in all clients (Flash and Java were close, but had the disadvantage of being owned by a single big player) Similarly, node.js got at least part of its popularity because it was the only thing that used _the_ language you can also run in the client. This levels that playing field at least a bit (completely, if it can manipulate the DOM with little friction) I expect to see many server-side languages will fairly soon compile to WebAssembly, so that they can position themeselves as an alternative to node (For example, I think Apple would be stupid if it wasn't working on a Swift-to-WebAssembly compiler). In my book, that is good; competition in that field will improve all tools.
- danjoc 10y agoAs I understand it, wasm is not asm, but an AST format for the JS VM. You're essentially compiling your c, rust, whatever, directly into the same thing JS is compiled to on the fly. But you do it in advance, so no parse time needed. Also, no GC, so good luck getting Java code on there for now. https://hacks.mozilla.org/2017/02/what-makes-webassembly-fast/ https://hacks.mozilla.org/2017/02/what-makes-webassembly-fas...