3 ms·
I read his point being that !important used for anything but the original intent is "code smell", and I'm fully behind that. He doesn't imply that you mustn't
by TonyTrapp 5y ago
I read his point being that !important used for anything but the original intent is "code smell", and I'm fully behind that. He doesn't imply that you mustn't use it for anything but its designed purpose, I'm sure he is enough of an engineer to know that sometimes you cannot stick to your ideals. He's probably well aware that some people have to rely on frameworks which already use !important, so they have to work around that by using !important as well. None of that contradicts what he says, but it's still a misuse of the feature.
- Dylan16807 5y ago> I read his point being that !important used for anything but the original intent is "code smell", and I'm fully behind that. It doesn't explain why using !important for the original intent isn't equally a "code smell". Unless that is smelly too, in which case there are even more questions to answer about why this is the workaround and why you're supposed to use it for the original intent despite that.
- exodust 5y ago> "...anything but the original intent" We're only hearing about the "original intent" now, via a smug tweet in 2022. It doesn't say much about someone who insinuates people "don't understand the cascade" if they don't follow an undisclosed design spec. And if they wanted it to be for font size only, they should have made it work only for fonts rather than any property.