4 ms·
The #1 place I struggle with this is with deleting CSS. I know we've got unused CSS hanging around, but because of the cascading/matching behaviors of CSS, I'm
by kevsim 6y ago
The #1 place I struggle with this is with deleting CSS. I know we've got unused CSS hanging around, but because of the cascading/matching behaviors of CSS, I'm way too scared to delete any of it.
I guess that's a strong argument for Tailwind and other CSS-in-JS frameworks, since the CSS disappears when the JS does.
- henrikn 6y agoAgreed, this can be difficult. An approach like BEM can help somewhat because you rely less on cascading. But then again, because it's tediously explicit, one may generate BEM class names in Sass or with PostCSS in a way that makes those long, explicit names harder to grep for…