Re:Google’s not-so-secret new OS
by spullara on Wednesday February 15, 2017 @03:40AM
(#13650598)
Java should have focused on manipulating the DOM rather than creating their own canvas. Was not obvious at the time though.
[ Parent
| on HN ]
Java did have an API for accessing and manipulating the DOM since (iirc) JDK1.4 -- org.w3c.dom and sub-packages. It was not at all well known or publicised, though.
Yep, this is what I was referring to. It would have been really interesting had people started doing things with it.
You mean like JavaScript nowadays uses Canvas and WebGL?
I think the key difference is you get to that incrementally. You start by "making the monkey dance" on an otherwise-static page, and you can work your way up to rendering everything on a fully-programatically-controlled canvas, a little bit at a time. Forcing you to do everything yourself from the start as TCL (remember tklets?) and Java did makes the barrier to entry much higher.
It's fairly rare to have web UI's built with canvas and WebGL - usually because they need to do something that is impractical using the DOM. They'll still use the DOM for the more conventional parts of the UI.