Re:Show HN: CSS Extras
by cluckindan on Tuesday October 14, 2025 @10:44AM
(#45580691)
Sure, the new syntax allows doing some nifty stuff with the cascade. In practice, however, I foresee most usage being simple one-time transformations of design tokens. I suppose it is more of a theme architecturing issue.
[ Parent
| on HN ]
Re:Show HN: CSS Extras
by chrismorgan on Tuesday October 14, 2025 @11:40AM
(#45581367)
It’s the same with Custom Properties. There are plenty of situations where they are useful at runtime, but a lot of their use is just a single definition on :root, and people really would be better served by the likes of Sass variables, because they foil all kinds of optimisations. You end up with things like color-mix(in srgb, var(--some-unreasonably-long-name), transparent) where it could have just been #1234567f. Quite apart from the runtime and memory costs, bundle size (even gzipped size) can frequently be reduced drastically by flattening eligible variables.