3 ms·
I was always really bullish on Web Components since the first whispers started... Then I wanted to start building non-JS websites. And suddenly "Web" Component
by Andrex 4y ago
I was always really bullish on Web Components since the first whispers started...
Then I wanted to start building non-JS websites. And suddenly "Web" Components just weren't an option. Now I've dug even further to SSR, and the shortcoming is painful. I don't want to use Next.js, I want to use HTML. I want standards.
Maybe in 4-5 years this will finally be a solved problem...
- dmitriid 4y ago> I want to use HTML. I want standards. > Maybe in 4-5 years this will finally be a solved problem... Of course it won't. And of course it won't be HTML. Thing is, Webkit wanted to start with HTML and with all things declarative [1] Google wanted to "move fast". Result? The need a few dozen more standards to patch deficiencies in WC design, and most of those standards involve piling more and more Javascript on top. See this 2022 status report: https://w3c.github.io/webcomponents-cg/2022.html https://w3c.github.io/webcomponents-cg/2022.html So now we are in year 12 of this catastrophe, and you are expecting it to end in another 4-5? If you want to build non-JS sites, web components won't save you. They require JS. They cannot work without JS. You're much better off using Next, Nuxt, SvelteKit, SolidStart, Marko... Anything that doesn't use them. [1] https://twitter.com/rniwa_dev/status/1352322006448947203?s=20&t=cLHSkKWlkqNTAgSmSCOMUQ https://twitter.com/rniwa_dev/status/1352322006448947203?s=2...
- lenkite 4y agoBut won't support for declarative shadow DOM solve the web components without JS problem ? I mean, maybe I am wrong, but with this and CSS, it looks as if we can gave custom elements in our HTML without any JS!
- WorldMaker 4y agoThere's still no agreed upon "template language" that is markup only in HTML. (That's what the above comments refer to as "Template Instantiation".) So while that template tag looks juicy it still doesn't actually do much of anything without JS. Except for possible the small set of web components where the internal markup is the exact same for every instance of the web component, maybe.