WDF - CSS 书写规范CSS已经写了很久了,但是感觉代码还是有点乱,不够漂亮。今天抽点时间整理一下手头上正在做的网站样式,顺带做一个自己比较适应的书写规范,以供以后参考。先暂时这样吧,其他以后再完善。
逻辑:大小 → 位置 → 边框 → 整体样式 → 内部文字 → 其他
编号
大小
位置
位置2
边框
样式
文字
其他
1
width
position
vertical-align
border
background
Font-size
float
2
height
z-index
border-spacing
Line-height
color
clear
3
overflow
margin
border-collapse
Text-align
Font-weight
display
4
cursor
padding
text-decoration
5
top
6
bottom
7
left
8
right