This is Dmitriy Likhten's Typepad Profile.
Join Typepad and start following Dmitriy Likhten's activity
Join Now!
Already a member? Sign In
Dmitriy Likhten
Recent Activity
Ok here are my points on css: It should be cascading. So set your colors and such early, set your classes to represent behaviors. Make multiple files to handle different needs. Css sucks in code reuse. How often do you want a structure div.foo (some styling) > div.bar > div.baz etc. Basically you keep repeating the same thing as you nest deeper. No computation. How often have I had to compute in my head the width of something being the width of the parent + borders + whatever, vs just something like "width: parent(width) - 10px;" its nice to declare but sometimes its good Bad layering. As in your HTML gets to mark up what styles it wants to use. Vs your html is marked up data, and your rendering engine will plow through the meaningful markups and apply shit. Remember if you want to change the looks of the site, you don't want to have to make more html classes in your html to change your layout. Skins don't work that way. We need CSS to be able to declare "if you include me, you must include these other css definitions as well" like ".foo { include , include , float: left, font-size: 10px;" See that makes sense because your CSS controls the layout not html controlling the layout except instead of "color="green"" you have "class="green_color"". CSS needs to be reworked. And at least less and sass make efforts to make better CSS, we still want that supported naively. O well I guess CSS is the new assembly language, you can code in it but you really should use C.
Toggle Commented Apr 30, 2010 on What's Wrong With CSS at Coding Horror
Dmitriy Likhten is now following The Typepad Team
Apr 30, 2010