DEV Community

Discussion on: 8 SCSS Best Practices to Keep in Mind

Collapse
 
marianban profile image
Marian Ban

Great article! I'm curious what others would say, but I found it useful to use !important for utility classes such as m-t-5 { margin-top: 5px !important; }.

Collapse
 
xavortm profile image
Alex Dimitrov

Utility class with important is a place where important can indeed be used. The tricky bit is that in general you rarely would want to use utility class at all. At least that's the goal. It pretty much says "Design seems inconsistent, let's make our code inconsistent too".