3 ms·
I think the future of JS is going to be a lot like Python - you write your code with JS libraries because of the ergonomics, but critical pieces of those librar
by brap 2y ago
I think the future of JS is going to be a lot like Python - you write your code with JS libraries because of the ergonomics, but critical pieces of those libraries are implemented in WASM under the hood.
For example, you’ll still write your React components, but the React framework itself might be written in Rust and compiled down to WASM to make everything snappier (e.g. DOM diffing).
I personally really love this pattern because it strikes a balance between speed and DX. Not everything has to maximize performance, and not everything has to maximize productivity.
- buu700 2y agoLike libsodium.js and pqcrypto.js. They're distributed as single self-contained JavaScript files, but under the hood have wasm embedded using the emscripten SINGLE_FILE flag with an asm.js fallback.