3 ms·
Here, "the problem" is that parsing JavaScript is very slow (and the second problem is that sending these files can be pretty slow, too). WebAssembly cannot rea
by Yoric 9y ago
Here, "the problem" is that parsing JavaScript is very slow (and the second problem is that sending these files can be pretty slow, too). WebAssembly cannot really ship JavaScript code. Well, I guess it could if someone were to write a JavaScript to native compiler and ship it as WebAssembly, but then you would end up with more problems:
- yet another JavaScript target, with possible incompatibilities, security issues, etc;
- you still need to ship the binaries, which will most likely be much larger (and much slower to parse) than your initial source code;
- "interesting" interactions between Wasm-compiled JS and browser-compiled JS, as well as the DOM, garbage-collection, ...