Multiple classes in body tag, multi-dimensional css structure or blueprint for insanity?
Posted
by mwiik
on Stack Overflow
See other posts from Stack Overflow
or by mwiik
Published on 2010-02-03T20:25:00Z
Indexed on
2010/03/23
12:03 UTC
Read the original article
Hit count: 273
This question is about an approach to css structuring, and so is more discussion oriented.
I'm working with some outsourced css where the body tags have multiple classes assigned, up to half a dozen. (To make things a little worse, none of the css selectors include an html tag which is making it confusing to analyze the css.) These body classes are then used to modify classed or id'd widgets within.
It seems like this approach is like adding an additional dimension to the css, perhaps in some attempt to create a structured css approach. Documentation might have helped, had we been provided any.
This differs from my approach where widgets are styled primarily via id'd divs, perhaps extracting the more generic elements into a class, i.e. div#MyWidget.widgets.
Any ideas on whether such an approach is maintainable, especially considering I am dealing with websites with thousands of pages including tons of legacy stuff, all done by different people with different skill levels? Thanks...
© Stack Overflow or respective owner