Link Details

Link 107094 thumbnail
User 320612 avatar

By glenstansberry
via nettuts.com
Published: Aug 26 2008 / 07:12

These CSS tips are gathered from some of the most respected designers on the planet. They have the portfolios to back their advice up, so you'll know that each tidbit of advice is of the highest quality.
  • 31
  • 0
  • 2046
  • 608

Comments

Add your comment
User 282119 avatar

Rob Signorelli replied ago:

1 votes Vote down Vote up Reply

Gotta say that I can't get on board with number 2. Keep it all on 1 line? How is that easier to scan than putting the declarations on separate lines? On separate lines it's easier to tell where one declaration starts and one ends, especially when one of the declarations is a rather verbose one like a background definition. Also, how does this save you any characters? In their example, you're using the same number of characters -- except that in one you're using spaces and newlines in the other. Sorry to nitpick that one item, but this one seemed really out of place from the rest of the list.

User 219110 avatar

jp0p replied ago:

1 votes Vote down Vote up Reply

I agree Rob. The only time I keep declarations on one line is if it is a single rule. It helps to save a little scrolling in your CSS file. #example {padding:10em;}

User 256617 avatar

dragmire replied ago:

1 votes Vote down Vote up Reply

I don't agree with 4 or 5, and I think 2 is a little too invasive of personal coding decisions to be a "principle"

User 328104 avatar

ahot replied ago:

0 votes Vote down Vote up Reply

My comment wasn't published on that page.
I just want to add something to 2: why don't he say about making class names short? It can save more traffic :)
BTW, Rob, you are right, space character can be equal newline character!
jp0p, you are right too. Now I think that they mean only scrolling size.

Add your comment


Html tags not supported. Reply is editable for 5 minutes. Use [code lang="java|ruby|sql|css|xml"][/code] to post code snippets.