Native DOM support might come later, but there's nothing stopping you from importing/exporting Javascript functions to WASM. Cheerp does this for example [1].
I am also curious about WebGL and/or canvas approach. This would allow bypassing the HTML and CSS mess not just JS mess.
Unless you have a good reason, I urge you to never do that. Even ignoring accessibility (which is pretty much completely ruined in this situation no matter what), you'll need to reinvent every single primitive widget you need yourself and have it work the same as it does on all platforms.
That's a shitload of code shipped to the user before you even write a single byte of code for your application!
No doubt someone will build that library though
It's been done, multiple times. See qt, gtk, etc.
Personally this revolution can't come soon enough.
Didn't Firefox also used to be like this? They reinvented every UI widget, and as a result felt like garbage on Mac.
Word. The sooner the better.
If you write all the rendering yourself, you can just output to a canvas but that kind of defeats the purpose. Having a JS layer for WebGL that calls into WEBASM for calculations etc should work fine though.