Re: [csswg-drafts] [css-values] Other options for value-agnostic delimiters (#6705)

> A top-level `!` is invalid in a `<declaration-value>`, just like `;`. Would `mix(<percentage> ! <start-value> ! <end-value> )` be better for SASS and similar tools?

No, the issue is that these tools rely on similar parsing logic to CSS, so they won't parse `!` in a CSS value specifically *because* it's not valid in any existing property.

> Yeah, given the existence of custom properties, semicolon and `!` are the _only_ possible inline separators; every other possible character is valid CSS property syntax in at least _some_ context.

That's not strictly true—not all `<declaration-value>`s are *useful* in `mix()`, since its value isn't directly accessible to JavaScript the way custom property values are. It has to be included in some registered CSS property's value, which means that any token that's not part of an existing well-known CSS property value (such as `@from` or `--`) is usable, at the cost of never being able to use it in any other value context in the future.

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


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

Received on Monday, 4 October 2021 22:00:12 UTC