Declarative CSS Modules and Declarative Shadow DOM adoptedstylesheets
attribute
#1000
Open
1 task done
Labels
Mode: breakout
Work done during a time-limited breakout session
Review type: CG early review
An early review of general direction from a Community Group
Topic: components
Topic: CSS
Venue: WHATWG
Milestone
こんにちは TAG-さん!
I'm requesting an early TAG design review of Declarative CSS Modules and the Declarative Shadow DOM adoptedstylesheets attribute.
When developing web components, web authors often encounter challenges with distributing global styles into shadow roots and sharing styles across different shadow roots. Declarative shadow DOM (DSD) enables creation of shadow DOM without JS, but adding styles to DSD requires the developer to either use JS to put a shared stylesheet into
adoptedStyleSheets
, or to duplicate the styles in a<style>
element for each component instance.We propose an enhancement to CSS module scripts that would allow developers to create CSS module scripts declaratively without a network request, and apply them to DSDs without the use of JS.
adoptedstylesheets
attribute mozilla/standards-positions#1081adoptedstylesheets
attribute WebKit/standards-positions#407Further details:
The text was updated successfully, but these errors were encountered: