Skip to content

symdiff/symdiff

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

symdiff

Build Status Coverage Status

Calculates symmetric difference between two arrays of strings. Main purpose is to detect unused CSS classes.

API

symdiff takes three arrays of strings as arguments:

  1. the classes used in CSS
  2. the classes used in templates
  3. classes to ignore

It outputs an object with the fields css and templates. For instance:

var css = ["grid", "grid-col", "grid-row"],
    html= ["grid"                        ],
    ignr= [        "grid-col"            ];

symdiff(css, html, ignr)
> { css: ["grid-row"], templates: [] }

License

Apache 2

About

Calculates symmetric difference between CSS and template classes.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors