5 ms·
What's the source for this, I do see they're the CSS co-designer, was this requirement originally written somewhere? I'm looking at the description of importan
by politelemon 5y ago
What's the source for this, I do see they're the CSS co-designer, was this requirement originally written somewhere? I'm looking at the description of important, and I don't see this intention carried through.
https://www.w3.org/TR/css-cascade-5/#important https://www.w3.org/TR/css-cascade-5/#important
https://www.w3.org/TR/css-cascade-5/#importance https://www.w3.org/TR/css-cascade-5/#importance
If the intention is indeed as described, then the CSS designers failed to communicate it properly, and not "a sign you may not understand the cascade properly."
- sfblah 5y agoIf the intention had been to comply with laws, why use “!important” as the keyword?
- akersten 5y agoFor the same reason we call it "accessible entrance" and not "government-mandated alternative door with ramp." Making the phrase more general is just good design.
- bigyikes 5y agoBut nobody is saying that accessible entrances should only be used for disabled persons and nothing else. Here, the author is asserting that there is only one valid use case of !important, and that it shouldn’t be used in the general case. If it shouldn’t be used generally, having a general name is bad design.
- jraph 5y agoIt should have been "!legally-required", or "lawful-font-size:" or the React way, "!enforce--only-use-this-for-legal-font-size-or-you-will-be-fired"
- isitmadeofglass 5y agoLikely because they felt the law is “not important”.
- simonlc 5y agoI don't know of it's a joke tweet, or a pompous person trying to make other devs feel inferior. The example or use case they describe doesn't even make sense to me. Nor does it even seem to line up with how CSS specificity or cascade works. "Here's a paper to write on, oh wait why are you drawing, this is a writing paper, you're doing it wrong!"
- throwawaylala1 5y ago> or a pompous person trying to make other devs feel inferior This is how I felt reading it as well. IMO Steven should exercise a little humility. It was bad design on his team's part. How is anyone supposed to know that there was only one super secret reason for "!important" to exist? Why not call it something like "!break-cascade-override"? They put an emphasize on making the language look "clean" over real world usability and this is the outcome.
- yreg 5y agoHow is a legal requirement different to a business requirement? Both need to be satisfied.
- ehsankia 5y agoBut not satisfying one may cost a lot more than the other, especially if it's a small difference that's small to catch visually.
- makeworld 5y ago>> Are there public discussion records about this? That'd be entertaining to read > Alas not. I wish there had been an agreement that after some number of years the records would be made public. https://twitter.com/stevenpemberton/status/1505958535976345609 https://twitter.com/stevenpemberton/status/15059585359763456...
- hacktavist24 5y agoWhen you say "If the intention is indeed as described," are you referring to the tweet in the submission? Because it looks like the intention is indeed so described in the links you give: > This CSS feature improves accessibility of documents by giving users with special requirements (large fonts, color combinations, etc.) control over presentation.
- Vinnl 5y agoYeah, I seem to recall it was added in Firefox to solve some browser chrome styling issues, or something like that. Anyone any idea where I got that idea from?