3 ms·
No, you would end up with: .selector1, .selector2 { color: green } .selector3, .selector4 { color: red } .selector1, .selector3 { width: 100px }
by lambda 15y ago
No, you would end up with:
.selector1, .selector2 { color: green }
.selector3, .selector4 { color: red }
.selector1, .selector3 { width: 100px }
.selector2, .selector4 { width: 200px }
No variables, no multiple classes. Now, I'm not saying that this is better than variables, or that variables won't make it easier to manage. But you don't have to repeat attributes or use many classes for each element currently in CSS, you just have to organize it a bit differently than you might expect at first.
- creamyhorror 15y agoAnd that's a lousy way to go, considering how spread out your properties can get. It's okay in small amounts when applied to a group of adjacent elements, but going any further makes no sense (unless you like using Ctrl+F a lot). I need an editor/IDE with a dropdown that displays the properties of any element in one panel, perhaps showing me where the actual stylesheet changes are made in a side column. Like editing styles in Firebug, only smarter. Anyone got a recommendation?