News for hackers. Stuff that matters.
Re:Why I don't use web components by traverseda on Thursday June 20, 2019 @11:03AM (#20233601)
It's a problem of mixing data and visual elements.

In a good model of the web, html is your data, css is your styling, and javascript doesn't really exist.

In another model of the web, your data would be your data, html/css would work together to form a scene-graph. Javascript defines the relationship between your data and it's scene graph.

That friction, are we using html as data or as part of our scene-graph, is what causes a lot of these problems.

I like web components because they bring you closer to having html be just your data. I like react because it brings your html closer to being just your scene graph. Both solve the same underlying problem from different directions.

Re:Why I don't use web components by shooner on Thursday June 20, 2019 @11:32AM (#20233915)
Well, I thought the 'good' model of the web was schema-based XML was your data, XSLT was your representation structure logic, HTML was your representation structure, and CSS was your representation styling. But the ship sailed on that one a while ago...
Re:Why I don't use web components by miohtama on Thursday June 20, 2019 @12:13PM (#20234305)
The road to hell is paved with XSLT. It was a good idea, but early 00s X-everything were terrible implementations.
Re:Why I don't use web components by HelloNurse on Thursday June 20, 2019 @12:25PM (#20234429)
XSLT is an unpleasant language (particularly for beginners) but implementations I've seen tend to be correct and stick to the standard; what trouble did you find yourself in?
Re:Why I don't use web components by dragonwriter on Thursday June 20, 2019 @03:25PM (#20236379)
> Well, I thought the 'good' model of the web was schema-based XML was your data, XSLT was your representation structure logic, HTML was your representation structure

Not XSL:FO?