From my understanding, it’s because WASM is pure (deterministic) and needs stateful entry points in order to work. For this reason, a JavaScript bit to interact with it is a requirement at the moment.
While it’s true you can’t do it in WASM directly, there are frameworks that interoperate between WASM and JS, such as Yew
One only needs to create an interface between them, since WASM is capable of calling JS functions. DOM manipulation then becomes as simple as calling a function in your language of choice, such as with web-sys
From my understanding, it’s because WASM is pure (deterministic) and needs stateful entry points in order to work. For this reason, a JavaScript bit to interact with it is a requirement at the moment.
Also WASM can’t directly manipulate the DOM so it can’t really be used for handling HTML/CSS, all front-end stuff still has to be done with JS.
While it’s true you can’t do it in WASM directly, there are frameworks that interoperate between WASM and JS, such as Yew
One only needs to create an interface between them, since WASM is capable of calling JS functions. DOM manipulation then becomes as simple as calling a function in your language of choice, such as with web-sys