Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

Structuring CSS code

After viewing the video "Organize CSS with Comments", is there anything on the web that goes into depth on how to structure CSS code?

1 Answer

Treehouse actually has a workshop that covers the best practices to write efficient CSS. I think Gil does a pretty good job at explaining what is generally the best methods to make your CSS code more efficient. But the more code you write, the more comfortable you'll become in CSS. And as you become more comfortable, you'll start to realize what you think works best for you and what you find as a waste of time.

Every web developer has their own style of writing code whether it's CSS, HTML, JavaScript, etc... but generally, we all follow a small set of rules known as "best practices." These best practices help making reading your code easier and would also allow for other people to work on and understand your code.

Hope this clears things up!