86
What's stopping WebAssembly from effectively replacing JavaScript?
(programming.dev)
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Follow the wormhole through a path of communities !webdev@programming.dev
Even if WASM gets some amazing feature, like super-fast DOM manipulation, it would still be used via API from JavaScript. WASM is a subset of JavaScript that mainly consists of low level operations. It's not exactly nice for writing code. It's like assembler in this respect — very fast, very efficient, but we still tend to prefer a higher level language.
How is WebAssembly a subset of JavaScript? Aren't you confusing it with asm.js?
He meant it as "wasm will be invoked by javascript" and not the other way around.
Ok but no one is talking about hand writing wasm. You write wasm with a language, such as rust, which already has great web frameworks such as yew (which replaces react) as well as leptos (which replaces solid.js). Leptos is already faster than react vue and svelte
I don’t know what you mean by WASM being a subset of javascript (maybe you mean AssemblyScript?) You can still program in higher level languages like C and have it compile into WASM as one would compile C to assembly.