- From: otabek-git <notifications@github.com>
- Date: Wed, 20 Dec 2023 19:01:09 -0800
- To: WICG/webcomponents <webcomponents@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <WICG/webcomponents/issues/909/1865407994@github.com>
> > I don't know that my two cents will be of much help here, but I strongly believe that this feature is a blocker for mainstream adoption of Shadow DOM. I appreciate that @justinfagnani sees "open stylable" shadow roots as a pragmatic path that unlocks the compositional powers of Shadow DOM without forcing everyone into a brand new styling paradigm. > > It is **of course** true that developers can take full advantage of Shadow DOM today if they are willing to understand the constraints and work with newer styling APIs. That is a great and valid choice that more greenfield tools should embrace. But it is also true that frameworks that would be taking advantage of the platform's compositional primitives (see `slot` support in [Vue](https://vuejs.org/guide/components/slots.html), [Svelte](https://svelte.dev/docs/special-elements#slot), [Astro](https://docs.astro.build/en/core-concepts/astro-components/#slots), [Qwik](https://qwik.builder.io/docs/components/slots/)) do not use Shadow DOM, but rely on custom JavaScript re-implementations. My _educated_ guess is that framework authors aren't doing this out of ignorance, but because the tight coupling of slot composition with unavoidable, strong style encapsulation makes a full embrace of Shadow DOM a very difficult sell for general audiences. > > If these features were no longer tightly coupled, I believe there would be many more tools taking full advantage of the clear benefits Shadow DOM offers. I would personally love to leverage Declarative Shadow DOM in Astro, but I don't see a viable way to do that if it means our users have to upend the way they think about styling. > > We don't need Shadow Dom css encapsulation, we have @scope css. We have to have either slot api in light dom or open stylable shadow dom which comes with slot. [mozilla/standards-positions#472 (comment)](https://github.com/mozilla/standards-positions/issues/472#issuecomment-1613651585) Safari added support for scope css yesterday https://www.webkit.org/blog/14885/release-notes-for-safari-technology-preview-185/ -- Reply to this email directly or view it on GitHub: https://github.com/WICG/webcomponents/issues/909#issuecomment-1865407994 You are receiving this because you are subscribed to this thread. Message ID: <WICG/webcomponents/issues/909/1865407994@github.com>
Received on Thursday, 21 December 2023 03:01:15 UTC