Cool post on Vitamin: Creating Sexy Stylesheets
I've thought about this stuff a lot in the creation of my own stylesheets, but it's cool to see it explicitly written.
I started organizing my css properties a couple weeks ago. Here's what I was doing:
#subNav{
- Display props
- Dimentions
- Margins
- Padding
- Border
- Background
- Typography
}
Basic logic being that I'm putting properties that affect layout first. You could argue that font-size impacts layout more than background, but I wanted to keep font properties together. And it makes sense to keep background near border.
I've been using inheritance-based tabbing to keep my CSS source readable after looking at
SASS. It's working pretty well, and I don't have to make nearly as many comments to keep it all straight.
No comments:
Post a Comment