- From: James May <css@fowlsmurf.net>
- Date: Thu, 14 Oct 2010 13:45:03 +1100
- To: Felix Miata <mrmazda@earthlink.net>
- Cc: www-style@w3.org
- Message-ID: <AANLkTin+Y60nXfB6KRb9quD8bnYCVqGjLtFaL2URr9FE@mail.gmail.com>
Regarding CSS compaction - surely this is just a tools issue? Valid CSS is fairly easy to reformat, after all. As to use of ID's - this has been encouraged for performance reasons. -- James On 14 October 2010 13:34, Felix Miata <mrmazda@earthlink.net> wrote: > The user theoretically has ultimate control by applying his own stylesheet. > I > was recently reminded by > > http://onwebdev.blogspot.com/2010/10/css-writing-efficient-user-style-sheets.html#comment-form > what a difficult task it can be for even a knowledgeable user to > effectively > exert that control. I suggest that certain things to discourage authors > from > employing troublesome techniques be incorporated into the CSS3 > documentation, > without here suggesting any methodology. > > Problem 1-CSS file compaction: > This is the stripping of all forms of unnecessary whitespace, including > newlines, from CSS files in order to minimize server load and maximize > download speed. The use of this technique seems to be rapidly spreading. > > It causes tools like Mozilla's Dom Inspector to show every rule on one > line, > a major impediment for any user attempting to isolate an offending rule > that > needs a compensating !important override. Even when viewed in an editor or > viewer that wraps the long line, the lack of whitespace makes navigating > and > understanding the rulesets difficult. > > It would be nice to see an average or more than a dozen or so "}" > characters > per newline character in any CSS source somehow become invalid. > > Problem 2-ID and class proliferation: > This should be self-explanatory. Authors don't seem to understand how to > let > inheritance do its job, preferring to apply at least one class and/or ID > for > virtually every element type and/or context. > > The more classes and IDs authors use, the greater the difficulty isolating > those that actually cause offense to the user, and the greater the time > required to build compensating overrides. At the same time, generic user > styles are all but useless. > > One solution might be to increase priority of instances of !important among > user styles so that each and every use of it takes precedence if in any way > applicable no matter how high the specificity is in author styles. I can't > think of any other way to deal with this other than user agents providing > options to completely disregard classes without disregarding CSS entirely. > > More problems to be described as time permits (unless someone beats me to > them all). ;-) > -- > "The wise are known for their understanding, and pleasant > words are persuasive." Proverbs 16:21 (New Living Translation) > > Team OS/2 ** Reg. Linux User #211409 > > Felix Miata *** http://fm.no-ip.com/ > >
Received on Thursday, 14 October 2010 02:46:00 UTC