12

I know there is an extension called Dust-Me Selectors for Firefox and also that it doesn't look at dynamic HTML generated by JavaScript.

I'm looking for tool(s) that can identify all unused selectors from a stylesheet, attached to several pages, with all the JavaScript running and checking selectors? The only option I know right now for this is manually checking files and finding unused selectors :(

In IDE's - I believe NetBeans provides a warning message when writing Java code, if a library is not under use. Without an IDE (NetBeans, Eclipse, Dreamweaver, etc) plugin to search for the selectors what are my options?

Also, is there a tool to check for unused selectors in the same file. I mean if all the JS, HTML and CSS code is in the same file.

1
  • 2
    That isn't really possible; you cannot predict what selectors are used by arbitrarily complicated Javascript. Commented Oct 31, 2011 at 18:19

1 Answer 1

11

I think that http://unused-css.com will do exactly what you want.

https://github.com/geuis/helium-css can help

as well as: http://razorfast.com/2010/11/21/announcing-cssess-the-bookmarklet-that-finds-unused-css-selectors/

Sign up to request clarification or add additional context in comments.

1 Comment

I tired out Helium... I liked how easy it was to find unused selectors... Thanks for the Answer...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.