46 ms·
Is WebAssembly the Return of Java Applets and Flash?
- deleted 8y ago[deleted]
- AnIdiotOnTheNet 8y agoYes, absolutely. The only significant difference is that it isn't a plugin.
- colanderman 8y agoNot at all. WASM doesn't define a UI component.
- pjmlp 8y agoSure it does, canvas and WebGL are good enough for everything else.
- colanderman 8y agoThose aren't part of WASM.
- AnIdiotOnTheNet 8y agoOnly because they don't have to be. Canvas and WebGL didn't exist back when Java and Flash were dominant, so they had to include equivalent functionality and step outside the DOM. It is meaningless to say that WASM is different because of this.
- colanderman 8y agoWhy? WASM fundamentally changes nothing about what web sites can do or how they do it. This article would make more sense if it were about Canvas, SVG, or any of the other JavaScript-accessible media elements which were added to enable Flash-like behavior from JavaScript. Those were game-changers. Claiming WASM makes the web more Flash-like is like claiming ES 6 makes the web more Flash-like that ES 5. It doesn't. The existence of DOM scripting and scriptable media elements does, and WASM doesn't change this. Claiming it does is just sensationalism.
- topspin 8y agoThe 'WASM is the new flash' argument only succeeds if you conflate at least all of WASM, canvas, webgl, webaudio, websockets and several other APIs and call it all 'WASM.' That is misleading in my mind. All of this stuff was developed independently of WASM and is usable without WASM. > It is meaningless to say that WASM is different because of this. Flash can and did extend the browser in arbitrary ways. WASM is operating within a standards regime and relies on standards based capabilities. We need not worry, for instance, that WASM is going to independently implement an API for some peripheral (camera, microphone, etc.) that duplicates or supplants some existing, standards based browser capability. While that remains true there is a demonstrative difference.
- AnIdiotOnTheNet 8y ago> The 'WASM is the new flash' argument only succeeds if you conflate at least all of WASM, canvas, webgl, webaudio, websockets and several other APIs and call it all 'WASM.' I think it is disingenuous not to include these features, because they didn't exist in any form when Java and Flash where big. > Flash can and did extend the browser in arbitrary ways. WASM is operating within a standards regime and relies on standards based capabilities. Yes, it did, because it had to. The features WASM is relying on for similar functionality did not exist at the time, there was literally no other way to do it. So your argument is that WASM is different because now, nearly 20 years later, these features are part of the standard web.
- topspin 8y ago> I think it is disingenuous not to include these features Before you ever heard the term "WASM" all of "these features" were available via plain old HTML5 and Javascript. Since that is the case why not argue that browsers themselves are the new Flash? And if so, what does WASM have to do with it? The answer to the last question is "nothing." "These features" did not have their origin in WASM. They existed prior to WASM and function independently of WASM because they do not depend on WASM. They are not WASM. Full stop. Conflating them all into WASM is, in fact, disingenuous.
- 8y ago
- Drakim 8y agoOne other big difference is that it's not owned by a single private company. Adobe tried to monetize certain flash 3d features at some point, but was rebuked so they withdrew their plans.
- AnIdiotOnTheNet 8y agoAlright, I'll give them that. However, I think this will, like it has with the rest of the web, lead to differences in how each browser handles the spec, various browser-specific extensions, etc. In that way, it's actually worse than having one company behind it.
- rusk 8y agoThe JS community currently deals with this by way of "polyfills" I wonder will such an approach be easier or harder with WASM ...
- zaarn 8y agoAny differing behaviour from the spec is supposed to be behind feature flags so that WASM Applications can reliably detect and use these.
- j45 8y agoWasm is the first major thing I can remember all the browsers agreeing on in a very long time, or ever. Agreeing of course, after trying to do it on their own and then realizing they were thinking a lot of the same things.
- SquareWheel 8y ago>Wasm is the first major thing I can remember all the browsers agreeing on in a very long time, or ever. Uh, flexbox, grid, fetch, service workers, even shadow DOM...? The cooperation between browser vendors has been exceptional over the last five years.
- rgomez 8y agoAnd! is a public W3C standard, is open source, is just a VM, doesn't define own UI components, is not controlled by any private corporation, will be maintained by browsers' editors, and maybe too many other things I'm not aware of... Remembering now the Monty Python's "What have the romans ever done for us" scene...
- nemetroid 8y agoDiscussion on the blog post to which this is a follow-up: https://news.ycombinator.com/item?id=17525858 https://news.ycombinator.com/item?id=17525858
- colanderman 8y agoIsn't the answer really, "no, because WASM doesn't allow you to do anything you couldn't already do with JavaScript"? I don't think anyone would complain about Applets or Flash if the only way they could interact with the web page was through the DOM. WASM enables nothing. It just makes a particular subset of JavaScript slightly faster. EDIT: I'm not talking about Canvas. That isn't part of WASM.
- rsynnott 8y agoEh, I'd still complain about them; they tended to be terribly poorly written and do a lot of unnecessary work, slowing things down and using too much power. Of course, so do random javascript things. I kind of miss the days of the HTML/HTTP-only web.
- colanderman 8y ago> Of course, so do random javascript things. My point exactly. The author is making the wrong comparison. WASM is JavaScript all over again, and, the HN NoScript crowd aside, that's not going anywhere soon.
- icebraining 8y agoThe author is replying to a comparison often made.
- colanderman 8y agoTo which the answer should be, "no, but Canvas might have, and here's why it didn't". Actually, that would be an interesting article to me, because in retrospective, I'm surprised we haven't seen more Flash-like Canvas-based sites. My suspicion is that Canvas's interactivity story isn't yet strong enough: you kind of have to roll-your-own interactivity, pending technologies such as addHitRegion() et al. [1]; most notably there's no support whatsoever for text-based interaction (e.g. text widgets). Hence why most web apps which would have been Flash a decade ago still stick to HTML instead of Canvas. [1] https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/addHitRegion https://developer.mozilla.org/en-US/docs/Web/API/CanvasRende...
- rgomez 8y agoIs this article's title clickbait?
- arghwhat 8y agoThe wonders of an article whose title is posed like a question is that the answer is always "no". No need to read it.
- steveklabnik 8y agoI had a conversation with someone about this on Reddit yesterday https://www.reddit.com/r/programming/comments/91s3pa/is_webassembly_the_return_of_java_applets_flash/e30ns6d/ https://www.reddit.com/r/programming/comments/91s3pa/is_weba...
- Vinnl 8y agoPerhaps an alternative that is more reflective of the actual content would be: Why WebAssembly is not the return of Java Applets and Flash.
- willvarfar 8y ago> Wasm has a really strong sandboxing and verification story that others simply did not. Eh, (P)NaCL had a very strong sandboxing and verification story. Wasm is, basically, NaCL in a form that Mozilla and the non-googles etc could accept. There are small implementation differences but the details are all non-important. It was all political. If they had accepted NaCL we'd have had what we have with wasm only we'd have had it years ago.
- rusk 8y agoAs did Java ... EDIT "does" - and of course it's flawed but the "story" is pretty great :-D
- colanderman 8y agoAnd JavaScript.
- rusk 8y agoIs Javascript the same though? I've seen numerous stories where security vulnerabilities have been introduced by way of third-party hosted libraries. Java has had signed classloading since the 90s.
- colanderman 8y agoThe same as WASM? Yes. Java? No, for the reasons you state.
- vturner 8y agoWASM itself isn't Java, Flash, or Silverlight, but isnt it another step in the ongoing multiyear process of replicating the features of those technologies in a way that they tried to accomplish: compile to one format and run it on multiple platforms? I think so, and the managers at Adobe and Sun must be kicking themselves for not somehow getting their runtime more open, modular, and standardized now that we see write once run anywhere with a few system hooks is all we need. Then again... It was a different world in the mid 2000s. The web standardization process? Ha, what was that? On a side note, I'm seeing more articles pointing out that WASM runs in the JS VM. Doesn't negate the whole advantage of speed for WASM?
- rusk 8y agoI think it's a step forward in that it's more integrated into the platform. Remember when TCP/IP used to be an add-on for an operating system? > managers at Adobe and Sun must be kicking themselves Both tried. As I recall Sun were blocked by Microsoft, and Flash was bundled as standard with Netscape from about 2001 onwards. Steve Jobs killed that stone-dead when he point-blank refused to support it on iDevices.
- zaarn 8y agoFlash on Mobiles was two sides, Adobe had a lot of difficulty to implement multi-touch correctly.
- wlesieutre 8y agoIf the Mac version hadn’t been a crashy dumpster fire, Steve Jobs might not have done that. Flash on Macs was always mediocre.
- rusk 8y agoBy blocking flash apps he increased the motivation for migration to native apps, so there was a sound commercial basis for this as well.
- Dolanator11 8y ago
- deleted 8y ago[deleted]
- jlebrech 8y agoyou could technically rasterise your ui/video/content to a canvas at 60 fps. so flash-like maybe and probably a step in the right direction, you can then code in sdl/qt/gtk/etc.
- kowdermeister 8y agoWhich is precisely the reason it be used as utility libraries. Most CRUD apps should remain JS/DOM based. For games I would say it makes sense to code the UI as well in WASM. I don't have an illusion though, it will be abused by devs heavily in the near future who dislike CSS/JS/DOM.
- jlebrech 8y agoi'd love to write markup that uses actually ui element names, even maybe no markup but also allow css for theming purposes. then js is to bind components to each other.
- kowdermeister 8y agoA bit late, but React is your perfect match then :)
- mattmanser 8y agoSeems very premature to say the Wasm has "won" when it's only just come out. People were saying Flash had "won" when all the browsers had it embedded by default a decade ago. Browsers removed Flash support, they might end up rendering Wasm useless by putting it behind loads of permission warnings. There's also the chance it'll end up lacking as it is and it'll end up being a useless appendage that gets killed off.
- zaarn 8y agoWasm doesn't need permission warnings since by default the sandbox is very restrictive. I think the reason Browser removed Flash was more because it was an absolute security nightmare for the Browser vendors and they had to fully rely on Adobe to patch the worst of it. Wasm on the other hand leverages the Javascript VM so browsers don't have that problem. And they don't depend on an external vendor either.
- bilbo0s 8y ago"...Wasm doesn't need permission warnings since by default the sandbox is very restrictive.." Upcoming changes to WASM include threading and shared memory. Unless browser makers implement those features in a manner that slows the machine to a crawl, WASM certainly will be getting some security warnings. Either because security minded organizations will disable it, or because browser makers will be honest and up front about the risks with those features. (There will be either security implications, or performance implications because they implemented the new features in a secure fashion.)
- eadmund 8y ago> If you built an applet in one of these technologies, you didn’t really build a web application. You had a web page with a chunk cut out of it, and your applet worked within that frame. You lost all of the benefits of other web technologies; you lost HTML, you lost CSS, you lost the accessibility built into the web. But that's also true of an application which relies on WebAssembly (or JavaScript): it loses all the benefits of the web, because in a very real sense it's no longer a web site, but is instead a program running in a web page. WebAssembly or JavaScript, neither is document-oriented; neither is linkable; neither is cacheable. It's Flash, all over again — except at least with Flash one could disable it and sites were okay. with WebAssembly & JavaScript, every site uses them for everything, meaning we get to choose between allowing a site to execute code on our CPUs, or seeing naught but a 'This page requires JavaScript' notice. It is the return of Flash, and that's a bad thing. We thought we'd won the war, but really we just won a battle.
- j45 8y agoSometimes a program running in the browser will be valuable when it's full window. Would I complain if I could run a full version of Word or Excel in the browser? The browser would become a universal interface in another way and decrease our reliance on particular operating systems.
- black_puppydog 8y agoYeah, or a full version of a monero miner...
- cmiles74 8y agoIn my experience, the application-on-browser products consume far more CPU and RAM than the application-on-OS products. For me, that's a pretty big deal: I need the laptop to run as long as possible on a charge. Right now, I would complain if I _had_ to run a full version of Word or Excel in the browser. Perhaps Web Assembly will drive this power usage down. But as it stands now, I actively avoid more than one of these app-on-browser products at a time.
- 8y ago
- drawkbox 8y agoIn a way yes. However there is other tech like WebGL, Canvas, web audio, web video etc, even apps, that make up good portions of what Flash brought, where WebAssembly is the compilation part of that and brings other languages into the mix as the source for the outputted wasm/asm. It also brings faster native runtime and hardware rendering capabilities when combined with other tech. Flash and Java never had native nor good hardware rendering support, the latter which was what ultimately killed Flash and the transition to mobile. Flash (and Shockwave director the first web 3d platform) actually were Java applets when they first came out then they switched to ActiveX plugins which really did have a good run of innovation on the web. Microsoft jumped on that to push ActiveX and Flash timing was just right as Microsoft was doing everything possible to kill off Java applets in as well as other platforms like Quicktime and Real Player. We owe lots of web interactivity to plugins and mostly Flash. I think with Chrome killing plugins there is a slight gap in platforms like Flash that push innovation, Java Applets never really took hold and were hampered by Microsoft as well as being slow. Microsoft even tried to make their own Flash in Liquid Motion in late 90s and again in 2005ish with Silverlight, just before mobile took off which changed everything. Mobile killed off plugins as much as Chrome did. Flash did lots of good things well or the best. Vector animation is one, SVG is pretty good now but Flash was still better. Flash for gaming and video was the best on the web for a long time. Flash was great for hitting web services/remoting before AJAX was as solid. Flash pushed using JSON data over XML though it could do both before javascript well. Flash was the original web sockets. Flash revolutionized interactivity, games and video. Flash made Youtube possible. Flash had display list and DisplayObjects that were like an early virtual dom. Flash was a market standard that the main goal was pushing interactivity forward and needed to to survive, Java applets did not keep up and it is harder to do with standards as they are slow. WebAssembly may be another Flash/Java Applet go round but plugins and now wasm can help push things forward as plugins did for many years. wasm may help that missing piece on mobile since it is just javascript in the end. Flash was a great interactive platform when under Macromedia and some under Adobe but Macromedia was really better at managing the development/technology platform that it was. Microsoft was going to buy them once before Adobe got them. Adobe let Flash languish a bit and they lost the hold. Flash is actually partly responsible for pushing web standards forward in html5, video, webGL, canvas, SVG even JSON and AJAX because they were all innovated on in Flash then brought to the browser. Flash with ActionScript3 even pushed forward javascript ECMA standards. AS3 was based on ES4 which Microsoft, Yahoo and others teamed up to kill, I think it was a solid ECMA version and quite fun and very readable and much like TypeScript [1]. I am a bit sad Flash is gone and wasn't looked after correctly by Adobe, if Macromedia stayed around it may have gone different and WASM would be Flash. However Flash ended up stuck in software rendering land for too long and buggy with security holes that didn't keep up on desktop nor was it ready for mobile. Adobe essentially sent both Director and Flash out to pasture (and Freehand/Fireworks which were good), but we still need something pushing innovation and standards are slow to do that, apps have somewhat become that in place of plugins like Flash today and wasm may help. [1] https://www.reddit.com/r/javascript/comments/34ps9z/why_was_es_4_skipped_but_typescript_is_taking_all/ https://www.reddit.com/r/javascript/comments/34ps9z/why_was_...
- nostalgeek 8y agoTLDR; no, because WebAssembly use browser API, when Flash and Applets do not. There is nothing that can be done in WASM that cannot be done with Javascript API wise, whereas Flash was able to do socket programming 10 years before webosockets and peer-to-peer 15 years before WebRTC.
- j45 8y agoWasm follows flash, java (applets) , jvm and even Javascript in the sense of being one codebase that will run on multiple platforms and potentially delivering on promises of the past. Still, Wasm seems unique in a few ways : - languages like rust have emerged to help address the browser issues of the past in other technologies - wasm can exist in the front or back end, in variety of languages but complies to one bytecode like the jvm. - wasm appears increasingly capable for both front-end or backend development, while not insisting on either. - wasm is the first standard I can remember where all the browsers (Chrome, Microsoft, Firefox, Apple etc) agreed on a baseline. This is much different than one company building flash, java, etc. Java applets and flash existed at a time when the html standard wasn't capable of rich frontend experiences, or deep backend. It's quietly an increasingly promising time, and my hope is the progress continues to gain momentum.
- madez 8y agoWebAssembly is yet another approach to withhold the source of programs from the ones that interact with it. By just sending part of the necessary binary logic to the user, it is ensured they can't easily be independent of the provider or create their own solution. If someone doesn't see what I'm talking about, then read about the AGPL; it exists to prevent what I'm talking about. Superficially, it is a shame Mozilla is working on this technology. However, it's official goal is to advance "The Web"©® which uses above mentioned effects to lead to centralization and lack of freedom for users. WebAssembly and some other modern browser features are the basis for the massive centralized providers we have today. That "The Web" leads to decentralization is a lie.
- dbaupp 8y agoIs minified JS fundamentally different? JS is already used as a write-only compilation target, and wasm doesn't seem worse than that (if you're concerned about its binary nature, there's a standard textual format). There's no technical way to enforce that code is shipped to people in an easily readable/editable format: JS or wasm or machine code can all be equally difficult to consume. Enforcing this requires a human solution, and that is exactly why viral copyleft licenses exist (including the AGPL you reference).
- madez 8y agoNo, unreadable, non-free JavaScript is not fundamentally different. Two wrongs don't make a right. Unreadable, non-free JavaScript is used to reach a goal. That goal is to withhold the source from the users to bind them to the service. This leads to centralization, power imbalances, and thus attacks on the freedom and sovereignty of the users. WebAssembly is a technology to achieve the formerly stated goal easier and more convenient. Of course, some people will be interested in that and work on it. Mozilla is working on this. So far so good (or bad). The issue arises when you combine this fact with the self-portrait of Mozilla as the one defending the rights and freedom of the users.
- Vinnl 8y ago> WebAssembly is a technology to achieve the formerly stated goal easier and more convenient. WebAssembly is a technology to achieve better performance on the web, and that as a side-effect happens to achieve withholding the source easier. Actually, it's pretty much like minifiers. And I guarantee you: the main reason most people are using minifiers is to improve performance, not to hide the source. That just happens to be a side effect.
- kowdermeister 8y agoEverybody who complained about JS the only language of the web should be extremely happy about WASM.
- fulafel 8y agoFor most high level languages, JS is for the foreseeable future a much better compilation target than WASM.
- WorkLifeBalance 8y agoWould it be possible to run the flash plguin/runtime in wasm to get the benefits of flash (easy to produce, a lot of legacy content) with the sandbox of wasm?
- gameswithgo 8y agosimple matter of programming!
- steveklabnik 8y agoIn theory, yup! I haven't seen anyone try it though.
- Vinnl 8y agoHa, maybe it's time for a WASM-revival of Gnash! [1] [1] https://www.gnu.org/software/gnash/ https://www.gnu.org/software/gnash/
- sebazzz 8y agoThat is only up to Adobe or the developers of that other OSS flash runtime/reimplementation.
- kodablah 8y agoNot too sure. You can probably lift it to LLVM bitcode, e.g. with [0], and compile back to WASM. But yes, not sure of the specific the DLL calls. 0 - https://github.com/trailofbits/mcsema https://github.com/trailofbits/mcsema
- ddevault 8y agoI'm typically sharply critical of the web, but I think this comparison is kind of silly. The biggest problem with Java Applets and Flash is the security issues, which were largely caused by giving web pages access to a second, less secure sandbox. WASM stays in the same sandbox as the rest of the web. Flash also had the problem of being proprietary and non-standardized with only one implementation, something WASM does not suffer from. For those worried about the "all WASM" pages looking like the old "all Flash" pages of yore, consider that Flash and Java applets had their own UI stack and WASM does not. The closest WASM has to that is OpenGL, but you've been able to make all-OpenGL apps with pure JavaScript for some time and it hasn't taken over the web with terrible sites yet. WASM code can interact with the DOM. I guess we could worry about native C/C++ GUI toolkits being ported to WASM, but the web community gets what you deserve for making Electron a thing. I don't like JavaScript in general but I don't see how WASM is any worse, and if anything it's quite a bit better.
- Marazan 8y agoFlash player had a open access spec and there was more than just the Adobe Flash Player as implementations. Pretty much every AAA video game of a certain period would have been using scaleforms Flashplayer for their user interface.
- kepgf 8y agoDoom 3 BFG comes to my mind.
- Marazan 8y agoWhy on earth is this being down voted?
- nostalgeek 8y ago> Flash player had a open access spec and there was more than just the Adobe Flash Player as implementations. No, the compiler maybe, Action Script maybe, but not the player. The player is entirely closed source and there is no open spec for the player. Or you need to show it to me. > there was more than just the Adobe Flash Player as implementations. Only Adobe's implementation could run all swf files. Scaleform was not an alternative flash player. Any attempt at creating an alternative and feature complete flash player failed. Flash the tech is not open, at all.
- bosaisi 8y agoNo.
- dep_b 8y agoThe thing about Flash was that it was pretty WYSIWYG and a lot of creative people flocked to it because it had strong multimedia capabilities. Personally I kind of missed the part where you could build really nice looking stuff without much technical expertise, nowadays you need to know all about CSS, Polyfills and JS quirks so there's always this limitation where you have to understand pretty technical stuff early on to get something done. Flash was more like using Premiere where you just edited your timeline with a bit of interactivity sprinkled over it, no movie editor ever had to get his hands dirty with some kind of scripting language or low level file formats just to edit a movie. I had a lot of "oh wow" moments at the end of the 90's and beginning of the 00's with Flash. It was like the web was warped into the future. Nowadays you can achieve the same but not as elegant. It kind of reminds me of how PC's had to catch up with the Amiga for years. Perhaps starting with Wing Commander things were really on par or better, almost 8 years later.
- basch 8y agoFlash Professional still exists (renamed Animate CC) and outputs to Canvas, WebGL, and Flash/AIR. https://www.adobe.com/products/animate.html https://www.adobe.com/products/animate.html I agree with you that it's a little sad that amateur animation fell a bit out of vogue, but the tools are right there for anyone whos interested to pick up.
- fipar 8y ago> I agree with you that it's a little sad that amateur animation fell a bit out of vogue, but the tools are right there for anyone whos interested to pick up. I have memories of being wowed by what creative people could do with flash in the 90s and I would not call that amateur animation. I think the problem (1) is we currently seem to be lacking in tools that let people skilled in the visual arts create things without knowledge of the mechanics, so to speak. It's like if in order to write a great song someone would first have to understand how a musical instrument is built. I would not call Amanda Palmer or Lee Ranaldo amateur yet I bet they probably can't build their own instruments. (1) I must make the disclaimer that for a couple of decades already I've been working only on the backend, so I may surely be missing part of the picture here. Edit: Fixed footnote mark.
- baybal2 8y ago>Other technologies were owned by companies >Java was owned by Sun Microsystems, Flash was owned by Adobe. But why does this matter? This is the reason corporate sponsors of WASM banish flash and, while at the same time, promote WASM.
- deleted 8y ago[deleted]
- thermodynthrway 8y agoJava Applets were before their time. It took JS/HTML the good part of a decade to catch up functionality and performance-wise
- titzer 8y agoThanks again, Steve, for a very clear and sober explanation of this. It's like you're inside our heads! You grok.
- steveklabnik 8y agoYou're very welcome!
- codezero 8y ago> That being said, the web standards process is healthier than its ever been Some disagree: https://www.eff.org/deeplinks/2017/09/open-letter-w3c-director-ceo-team-and-membership https://www.eff.org/deeplinks/2017/09/open-letter-w3c-direct... Obviously it’s better in aggregate than the web of applet and flash times, though.
- steveklabnik 8y agoOne failure does not mean the whole process is bankrupt.
- codezero 8y agoAgreed, and I realize that your point was (I assume) more about the historic hot mess.
- steveklabnik 8y agoThat’s also true. :)
- titzer 8y agoThe OP is really spot on. For the commenters that seem to have some underlying fear that WASM apps will be another incarnation of a "window in a window" or some horrible bitmapped graphics pane that does not fit into the web model: WASM is just a CPU. It's a bytecode format for expressing low-level, high-performance programs. It comes "batteries not included"--intentionally. By batteries, I mean APIs. WebAssembly modules must import everything they need from the outside. When embedded in JS and the Web, the first and still primary use case of WASM, that means modules can import functionality from both JS and the Web, and call literally anything that JS can call. That means WASM can (though still somewhat clunkily) manipulate the DOM, WebGL, audio, service events, etc, through all of the same APIs that JS can do. There is nothing that prevents a WASM app from looking and feeling exactly like something written in JS. To reiterate: WASM does not require you to drop down to canvas or render fonts yourself. You can call out to JS or direct to WebAPIs! (again, it just happens to be clunky to do this from C++.) But other languages are working on bindings that make this much nicer. Rust anyone? :) What WASM gives the web is a proper layer for expressing computation. The APIs and paradigms that build on top of WASM are independent, swappable, interposable, by design. Because it's a layer for computation, and a low-level one, it is by nature language-independent. As Steve mentioned, adding languages to the web one by one does not scale. Thus WASM.
- TeMPOraL 8y ago> To reiterate: WASM does not require you to drop down to canvas or render fonts yourself. The fear isn't that it requires that. The fear is that it enables that. The web is, and has been over the past two decades, in the constant state of war over control between publishers and consumers. People - and especially businesses - making pages would like to have 100% control over how the webpage/app looks and is being used. But the users would like to have some control over what they're viewing too[0]. The most widely known battle in this war is the battle for ad-blocking. The publishers want you to view lots of ads. You want just the content, without any of the ads. So far, the technology (and economics) favors the user, but it's not a given. The balance of control on the web was always maintained by the technologies on which the web standardized on. Pure HTML, or even HTML+CSS, strongly favours the user. JavaScript tilts the balance significantly towards the publishers, as now they can (and do) generate content with code, which renders the page difficult to interpret and modify on the user end. One of the biggest complaints about Flash was how shitty the pure-Flash/mostly-Flash webpages were. That's not an intrinsic problem of Flash - this happened, because Flash gave the publishers too much control. And publishers (again, especially businesses) will use (and abuse) any control they're given. The fear here is, that WASM against tilts the control in favour of publishing, which will lead to abuse and web becoming a much worse place for the consumers. If WASM will, by virtue of efficiency, enable publishers to embed a browser they control within the page, the publishers will use this, because this would single-handedly eliminate most ad-blocking, userscripting and scrapping efforts. -- [0] - and the power users, like myself, would like to have 100% of that control - think of how much better the web would be if the data was always published in machine-readable format, without tons of bullshit paginations and stylistic choices to scroll and click through. For instance, when looking for current weather, I want to input my location and a time span, and get weather data. I want to be able to script that. I don't want to waste time looking at ads, pretty pictures, non-relevant text and links.
- GenericsMotors 8y agoWonder what its effect on the popularity of Javascript will be, given that it can be used as a compilation target for pretty much any language (?).
- steveklabnik 8y agoI'd look to the server side; JavaScript is still quite popular there even though you can use any language.
- GenericsMotors 8y agoIsn't that just a side effect of frontend devs being able to use their existing JS knowledge serverside? I'd expect the reverse to happen as well to some degree since currently backend devs are somewhat "forced" to take on JS if they want to do any frontend work. Or does that seem less likely to you?
- steveklabnik 8y agoBy that logic, they will also stick to JS instead of using WebAssembly. So, same result. I think the “backend dev migrates” case is less likely, in a purely math sense. The number of backend devs forced to do front end is smaller than the number of frontend devs.
- jhabdas 8y agoIf anyone wants to take a quick look at running a WASM app to take your understanding from theoretical to applied look no further than Fabrice Bellard's excellent BPG Image format and the JS decoders which build for asm.js and wasm.
- tboyd47 8y agoKlabnik makes a strong case for WASM here, and one I haven't really seen anywhere else. Now the question is, who will make the first major framework on top of WASM, and for which language?
- steveklabnik 8y agoThank you! I bet you know which language I'm betting on ;) That said, I don't think a framework is really the thing; I think JavaScript users using wasm in libraries is a much bigger growth area for wasm, at least in the short term.
- tambourine_man 8y ago> But implementers are important; they control the web. I’d argue users are an even more important part of the equation. If the UX sucks, no one will use it and you’ll have implemented an empty spec.
- mrfusion 8y agoRemember when restaurant menus were in flash and you couldn’t open them on your phone!
- PretzelFisch 8y agoYou could run flash on android.
- artmageddon 8y agoNot all of us used Android when Flash was available for it
- Dolanator11 8y agoNo, not by a long shot. Remember how much time it took for an elaborate Flash animation to load? Sometimes you had to wait for more than a minute before anything even rendered on the page. And Java applets.. were a joke. A Frankenstein approach to embedding applications in the browser. By contrast, Wasm IS Javascript, even if the source code might be from another language, it's a target for compilation. It will only be able to do whatever the browser allows it to do, ie access Web APIs, work with the DOM or just do computations that don't output anything UI-wise. This is not the return of badly executed and badly thought-out plugins, this is "native applications in the browser" done right.
- fixermark 8y agoOne can only hope.
- pritambarhate 8y agoI also worry that WASM will just bring another era of non-standard Flash and Java Applet like UI design. Just check this QT demo: http://example.qt.io/qt-webassembly/SensorTagDemo/SensorTagDemo.html http://example.qt.io/qt-webassembly/SensorTagDemo/SensorTagD... Then there is this gallery demo: http://example.qt.io/qt-webassembly/quickcontrols2/gallery/gallery.html http://example.qt.io/qt-webassembly/quickcontrols2/gallery/g... The right sidebar right now doesn't scroll with standard mouse wheel. I had to scroll it using mouse drag.
- xigency 8y agoThis is actually terrible.
- motbus 8y agoSome people say that webassembly is like java applets or flash... Then i stop talking to them
- bluetwo 8y agoYes.
- deleted 8y ago[deleted]
- craftoman 8y agoWebAssembly is only the payback of any low level programming languages to JavaScript. Truth is, there should be opening positions so they could eat some pieces of the big pie too cause all those JavaScript kids became rock stars for no reason.