sudo apt-get install node-less ruby-sass npm install purify-css
toglie gli stili non utilizzati. The HTML files are loaded by PhantomJS and JavaScript is executed. Used stylesheets are extracted from the resulting HTML. The stylesheets are concatenated and the rules are parsed by css-parse. document.querySelector filters out selectors that are not found in the HTML files. The remaining rules are converted back to CSS.
uncss http://davidwalsh.name > styles.css
csstidy /var/www/prj/css/main.css \ --preserve_css=true --optimise_shorthands=2 \ --remove_bslash=false --merge_selectors=2 \ --silent=true --compress_font-weight=false \ --template=low --silent=true \ > /var/www/prj/css/main.css.clean
csslint --ignore=ids,important,unique-headings,unqualified-attributes,box-sizing,outline-none,overqualified-elements \ main.css > lint.txt