News for hackers. Stuff that matters.
Re:CSS Classes Considered Harmful by wavemode on Wednesday July 17, 2024 @09:50AM (#40985951)
> Custom properties can be applied to any element as well.

Well, no, they can't. That's the point the article is making.

Classes can compose arbitrarily, i.e. class="size-small size-big"

Whereas data-size="small big", while valid syntax, would not be styled by a rule targeting elem[data-size="small"]

There are no comments on this comment yet.