2 ms·
My remembered experience of Java applets was that they loaded slowly, they required Java to be installed on the client computer (so they didn’t work out of the
by josephg 6y ago
My remembered experience of Java applets was that they loaded slowly, they required Java to be installed on the client computer (so they didn’t work out of the box for most people) and obviously they only run JVM code. Java applets also lived in an element on the webpage - which isn’t true of wasm. (But maybe there was also a way to run Java applets “headless”). I used to close websites if the Java applet loader appeared because otherwise I would be waiting for ages, and most of the time it wouldn’t work anyway because Java would be out of date or broken, or at best just slow and ugly.
In comparison, wasm apps have their own VM that is embedded into the browser. So there’s nothing extra for users to install (like the jvm). It’s small and lightweight, has (almost) no runtime SDK and it works on phones. I suppose you could write a compiler from C & Rust to Java byte code, ignoring most of the JVM’s features. But that big landscape of exposed features through the JVM still needs to be shipped somehow, and it’s a sandboxing nightmare that wasm just doesn’t have to contend with. Also let’s not forget that Google got sued over their use of Java by Oracle. I don’t want the web of the future to depend on any IP owned by oracle - that sounds like a disaster waiting to happen.