I have two questions..
1. How do you list your CSS attributes? Alphabetical order? Is there any specific order that needs to be followed? I'm just trying to make things consistent so I'm thinking about having everything alphabetically.
For instance, instead of this:
this
2. I was reading a CSS expert's blog and he preferred to setup a class for common attributes, and declare multiple classes in the tags.
For instance, instead of this
Do this
Thoughts?
1. How do you list your CSS attributes? Alphabetical order? Is there any specific order that needs to be followed? I'm just trying to make things consistent so I'm thinking about having everything alphabetically.
For instance, instead of this:
Code:
.details_right
{
display: block;
width: 28%;
float: left;
padding:0 1.5em 1em 1em;
}
this
Code:
.details_right
{
display: block;
float: left;
padding:0 1.5em 1em 1em;
width: 28%;
}
2. I was reading a CSS expert's blog and he preferred to setup a class for common attributes, and declare multiple classes in the tags.
For instance, instead of this
Code:
----------------------------
.details
{
display: block;
float: left;
padding:0 1.5em 1em 1em;
width: 28%;
}
----------------------------
<div class="details">
Do this
Code:
----------------------------
.block {display: block;}
.float_left { float: left;}
.details
{
padding:0 1.5em 1em 1em;
width: 28%;
}
----------------------------
<div class="details block float_left">
Thoughts?