CSS Style overload - Remove unused CSS Styles
I design sites (not well most of the time!) and often pinch bits and bobs from the various CSS stylesheets I’ve created over the years, generally I normally end up coming up with something that looks at least half decent!
However, all that cutting and pasting leaves my stylesheets in a mess - with tonnes of unused CSS styles!
I spotted a reference to Dust-Me Selectors today on San Baldo, and using this fantastic Firefox Extension I have managed, in the space of minutes to reduce on stylesheet from an unmanageable 600 lines to a mere 200!
It extracts all the selectors from all the stylesheets on the page you’re viewing, then analyzes that page to see which of those selectors are not used. The data is then stored in your user preferences, so that as you continue to navigate around a site, selectors will be crossed off the list as they’re encountered.
You’ll end up with a profile of which selectors are not used anywhere on the site.








{ 7 comments… read them below or add one }
thanks for reporting my post / blog
You’re welcome! It’s a fantastic little tool!
HI,
But this tool will help only to show the one unused in current page. It will be helpfull if it show unused css in thw whole site, becuase we will be able to delete tht classes from css….
Hi Sujith,
I think the key is that you have to browse around the whole site with it.
Hi Keiron ,
Thanx. i too think thats the only work around.
it has an option to spider your site, all you have to do is point it to the site map. i really cant believe how good this plugin is.
magic!!!!!
I haven’t seen that - is that in a new version?
Leave a Comment