8
Quick tip: Nesting related properties for more readable CSS (medium.com)
8 years ago from Matt Sisto, Lead UX Designer @ Upserve
8 years ago from Matt Sisto, Lead UX Designer @ Upserve
Good tip, I've also seen devs separate style chunks with a line break.
.foo { position:absolute; top:0; left:0; padding:0; margin:0; color:#fff; }
https://github.com/necolas/idiomatic-css
I've been doing this myself for a while now.
Yeah, I'd rather group together similar properties and then separate them with line breaks than muck around with indentation. Plus, indentation could break .sass
files.
Designer News
Where the design community meets.
Designer News is a large, global community of people working or interested in design and technology.
Have feedback?
Login to Comment
You'll need to log in before you can leave a comment.
LoginRegister Today
New accounts can leave comments immediately, and gain full permissions after one week.
Register now