You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[css-shadow-parts-1] part should be a superglobal in the HTML spec #3424
I arrived at this draft from a few links about @apply being abandoned. After reading this spec, I, in no way, see how this is related -- it doesn't solve the same problem.
@NullVoxPopuli Sorry, I don't know why this is listed as an alternative solution (I am not at all familiar with postcss-apply). Please take that up with the authors of the postcss-apply doc.
The motivating use-case for @apply was passing bags of properties into custom elements, so you didn't have to reinvent all of CSS as custom properties just to allow arbitrary styling of something inside a shadow tree. That use-case was replaced by ::part().
The more general use-case of using @apply to compose classes, however, isn't addressed by this. (And @apply is still bad for that, for all the reasons I gave in my blog post. We probably want to eventually do @extend to address that case.)
Activity
NullVoxPopuli commentedon Feb 29, 2020
I arrived at this draft from a few links about
@applybeing abandoned. After reading this spec, I, in no way, see how this is related -- it doesn't solve the same problem.The path I took to get here:
I'm confused. I want to compose CSS classes :-\
fergald commentedon Mar 2, 2020
@NullVoxPopuli Sorry, I don't know why this is listed as an alternative solution (I am not at all familiar with postcss-apply). Please take that up with the authors of the postcss-apply doc.
tabatkins commentedon Mar 4, 2020
The reason is that my blog post about abandoning @apply says precisely that. ^_^
The motivating use-case for @apply was passing bags of properties into custom elements, so you didn't have to reinvent all of CSS as custom properties just to allow arbitrary styling of something inside a shadow tree. That use-case was replaced by ::part().
The more general use-case of using @apply to compose classes, however, isn't addressed by this. (And @apply is still bad for that, for all the reasons I gave in my blog post. We probably want to eventually do @extend to address that case.)
annevk commentedon Nov 18, 2022
@fergald any ETA on this? This feature has shipped reportedly so this seems overdue. If it's superglobal it should be in DOM probably.
fergald commentedon Nov 21, 2022
@mfreed7 @domenic Please take a look.
mfreed7 commentedon Dec 5, 2022
LGTM to make
partsuperglobal.