Skip to main content
Participating Frequently
March 24, 2017
Question

Finding Unused Styles

  • March 24, 2017
  • 1 reply
  • 1312 views

Hi,

Is there a feature in Dreamweaver 2015 to determine if I have a css style assigned but it is not defined?

Thanks

This topic has been closed for replies.

1 reply

Jon Fritz
Community Expert
Community Expert
March 24, 2017

It's not something I've ever seen in the program before.

I've used the Firefox Dust-Me Selectors add-on in the past when I needed to find that kind of info, and it seemed to work pretty well.

cosmarchyAuthor
Participating Frequently
March 26, 2017

Dust-me is the exact opposite of what I'm after - it finds styles which are defined but unused.  I'm looking for used styles which are undefined!!

I would have thought this would be quite a useful feature for DW.  Saves using styles which are undefined and the pages not presenting properly.  Easily missed when you have a large number of styles or a large webpage.

Nancy OShea
Community Expert
Community Expert
March 26, 2017

How do you manage to use styles that are not already defined in your CSS code?

My workflow is to use Available Classes from Code Hints and/or the HTML Properties Panel.  In other words, if it's not defined anywhere in my CSS, it's not an available option.  See screenshots.   I'm using Bootstrap CSS in this example.

Nancy

Nancy O'Shea— Product User & Community Expert