Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[@sheet] What happens with multiple @sheet definitions with the same identifier? #937

Open
aluhrs13 opened this issue Jan 22, 2025 · 1 comment
Assignees
Labels

Comments

@aluhrs13
Copy link
Contributor

What happens with multiple @sheet definitions with the same identifier? First-definition wins, or do they get merged like @layer? Again, this was brought up in the CSSWG but not resolved (w3c/csswg-drafts#5629 (comment)). Note that it's possible to have a "Flash of other-styled content" if it's last-defintion-wins, as the first definition may apply, then a later definition from an external CSS file may override it.

@aluhrs13 aluhrs13 self-assigned this Jan 22, 2025
@kbabbitt
Copy link
Member

It seems like the "flash of other-styled content" case could apply even in the merge case? As in, we might discover a later definition in an external CSS file that overrides something we already know about. Or am I misunderstanding?

Initially I would lean towards last-definition-wins for consistency with things like @keyframes, but if there are use cases for merging I'd be interested to hear them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants