|114||File Size kb||6|
The way to beat CSSitis and Divitis is to apply small soldiers of classes that become Classitis.
It’s like taking small doses of poison to build up an immunity
— Jimmy McGill, Better call Saul
This is the complete opposite to how you have been coding for years if not decades. Using less classes, targeting HTML elements, using more properties keeps your code clean. On the outside to users, it may look clean, but on the inside, its not so pretty.
Clearly, for large sites that change many hands with different levels of CSS skills, the file can become a burden.
Or simply designers and developers may not know or lack the time to fix these things, and just do what works, I've done this many times.
You may find yourself creating more classes, the specificity stack is getting bigger, you go on holiday, fixes were required, more code, more potential problems.
The goal is to reduce your score by mainly focusing on the CSS to make a decent comparison. The styling won't be like for like, it's more of achieving a similar look with a leaner, systematic file.