We have the same thing in Javascript, we call it 'hacks.js'. That's the place you go when things are broken and you're not yet ready to pay down tech debt. Hacks.css sounds nicer than shame.
Shame.css
21–30 of 57 posts
Re: Shame.css
#22Been doing this for years. I usually call the file ie8.css, though.
Re: Shame.css
#23Been doing this for years. I usually call the file ie8.css, though.
Re: Shame.css
#24Pedantry: can we call it "guilt.css" instead? In psychological literature, guilt is defined as the "I did something bad" emotion, shame is the "I am bad" emotion. The crucial difference between them is that guilt can be fixed by making amends. That seems like exactly the mindset you want to encourage with this: guilt.css implies that you feel guilty about all the hacks you have and want to make amends, while shame.cs…
You went slightly overboard there I think.
It's possibly called shame because the style sheet is public, _it shames the author_.
Re: Shame.css
#25Cool idea, but considering IE8 support is on its way out from developers what hacks are left we need to use? Using overflow: hidden instead of resolving a problem is just lazy, it's not a hack, it's plain lazy. Cool idea in theory and perhaps might have been helpful in 2008, but it's 2013 and browsers are all at a point now where we can use CSS and not have to worry about consequences or support except for maybe browser vendor prefixes.
Re: Shame.css
#26Why is overflow hidden a hack?
overflow: hidden; is not a hack. It can do a lot of things which in his opinion are hacks (wtf). Suggested reading: http://colinaarts.com/articles/the-magic-of-overflow-hidden/
Re: Shame.css
#27Pedantry: can we call it "guilt.css" instead? In psychological literature, guilt is defined as the "I did something bad" emotion, shame is the "I am bad" emotion. The crucial difference between them is that guilt can be fixed by making amends. That seems like exactly the mindset you want to encourage with this: guilt.css implies that you feel guilty about all the hacks you have and want to make amends, while shame.cs…
Re: Shame.css
#28This is a great idea and to be honest the only time I ever use hacks is when I am adding in compatibility for IE8. I disagree with the !important declaration though. I use LESS for writing CSS and while it's definitely a valuable asset to have, the ability to nest and have super specific queries generated means when you'e writing media queries, you sometimes don't want to have to replicate the nesting and specificiti…
Re: Shame.css
#29Related: is there a good short "remedial CSS for programmers" book or something?
Re: Shame.css
#30- The name - as already has been raised by others implies that you have done something wrong.
- Adding to the file requires a degree of confidence and maturity among your team and a level of trust among the group.
- The existence of such a file might reduce effort on the part of some. After all if "shameful" hacks are OK, why bother with real solutions?
- Internal refactoring as an separate independent initiative is sometimes difficult to justify from a financial or political perspective.
In a group with self-aware, well educated, and motivated developers, these concerns might be rather small. But in many larger organizations (with practices that sometimes make Dilbert comics appear tame), this would not work as well for these and other related reasons.
Don't get me wrong, I really like the idea. And since css code is relatively "free" to be included in an arbitrary file, calling out questionable code in this way does seem to have its merits. Perhaps its the use of the term shame that tips me off, but that is a concept that is understood very differently by different people and different cultures. So - like many suggestions - it might work well depending on your group, but is unlikely to be adopted as a universal best practice.