zmoazeni / csscss

A CSS redundancy analyzer that analyzes redundancy.
http://zmoazeni.github.io/csscss/
MIT License
2.92k stars 151 forks source link

Terminology #78

Closed necolas closed 10 years ago

necolas commented 11 years ago

README says stuff like

{.contact .content .primary} and {article, #comments} share 5 rules

Do you mean declarations?

zmoazeni commented 11 years ago

Yeah, my bad on that one.

robme commented 10 years ago

After installing this and trying it, I'm not sure that it actually does what I need.

I have a CSS file that due to someone's sloppy merging, contains many duplicate rules. My understanding of the word "rule" is that it's something like this:

.class {
  property: value;
  property-two: value2;
}

So I mean that it's the actual selector rule (.class) that is duplicated, and it's this that I need to find. Can csscss help with that? It seems to just find duplicate declarations/properties within the rule, which is also very useful, but not quite what I need.

Edit: I found a tool called uCSS which finds duplicates.

zmoazeni commented 10 years ago

Yeah, csscss treats different instances of .class as one. So that's not a good fit for what you're looking for.

zmoazeni commented 10 years ago

Changed to "declarations" in 0630d341252dd4e576151f7fa228432655ab92f8 and released in v1.3.3