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!
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
Scanning for unused or overwritten styles
Now frame works such as Foundation and Bootstrap are getting ever more popular we are building on top of existing code which tends to mean overwriting a great deal of existing styles.
Could anyone recommend a good reliable method of scanning the stylesheet and deleting all the styles not used anymore and out putting a new stylesheet.
Guil HernandezTreehouse Teacher
Chrome's dev tools has a really handy tool called Audits that allows us to do just that––audit our code. It lets you know which styles are unused. To use it:
- Open Properties > Tools > Developer Tools
- Click on the Audits tab within the Developer Tools window
- Ensure the Web Page Performance option is checked.
- Click Run