20 ms·
CSS Utility Classes and “Separation of Concerns”
- dpkonofa 9y agoI feel like the examples shows are a little disingenuous. He's ignoring the entire fact that CSS rules cascade and that design has hierarchy. I don't see a functional different between .media-card .media-card__image and .media-card img yet the 2nd is actually semantic and not reliant on specific markup. The biggest difference to me is that .media-card__image doesn't have to be an <img> element and I don't see how that's a benefit.