Re: [csswg-drafts] [CSS Import Once] @import-once, or some syntax for importing a stylesheet only once (#6130)

> Is there any precedent in CSS where the first occurrence of something wins? Don't get me wrong, that is the only reasonable way to implement this I think, but seems like a weird thing which I'm not sure has a precedent.

Cascade layers.

----------------

- What happens if you import once with a different cascade layers?

----------------

> This is the single most notable feature of native CSS preventing everyone from writing highly re-usable modular vanilla CSS code.

I don't see how this would be solved by `@import-once`.

Can you give more detailed examples where vanilla CSS could have been more re-usable and modular but that this was prevented by this specific aspect of `@import`?

I feel like there is some step or aspect that I am missing.

-- 
GitHub Notification of comment by romainmenke
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6130#issuecomment-1855317935 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 14 December 2023 07:31:57 UTC