News for hackers. Stuff that matters.
Re:The State of WebAssembly 2022 by lisper on Monday June 20, 2022 @02:04PM (#31813491)
> JavaScript cannot be compiled to WebAssembly

Wait, what? Why? Is WASM not Turing-complete?

Re:The State of WebAssembly 2022 by sunfish on Monday June 20, 2022 @02:43PM (#31813991)
Wasm is Turing-complete. What people typically mean by this is that in a browser context, compiling JS to Wasm does not currently make it run faster than just running the JS as JS.

Javascript can be compiled to WebAssembly, and there are people doing it:

https://bytecodealliance.org/articles/making-javascript-run-...

Re:The State of WebAssembly 2022 by goatlover on Monday June 20, 2022 @02:32PM (#31813855)
You need a runtime like the browser or Node in WebAssembly. I suppose you could write one in Rust and then compile it to wasm. But then what do you gain by doing this?
Re:The State of WebAssembly 2022 by AndrewDucker on Monday June 20, 2022 @02:29PM (#31813817)
It would need a JavaScript interpreter to go with it.