[DEPRECATED] Lint and minify CSS and LESS
JavaScript CSS
Latest commit e9754cd Feb 11, 2016 @sindresorhus deprecate
Failed to load latest commit information.
tasks tweaks Aug 29, 2014
test tweaks Aug 29, 2014
.editorconfig minor tweaks Aug 5, 2014
.gitattributes Update and add dotfiles Aug 25, 2012
.gitignore Reporting add-ons for RECESS. Fixes #39 Dec 22, 2013
.jshintrc minor tweaks Aug 5, 2014
.travis.yml Update .travis.yml Feb 8, 2015
Gruntfile.js use Mocha directly for tests Aug 5, 2014
license minor tweaks Aug 5, 2014
package.json 1.0.1 Feb 24, 2015
readme.md deprecate Feb 11, 2016

readme.md

Deprecated since RECESS is no longer maintained


grunt-recess Build Status

Lint and minify CSS and LESS using RECESS

Issues with the output should be reported on the RECESS issue tracker.

Install

$ npm install --save-dev grunt-recess

Usage

Lint

require('load-grunt-tasks')(grunt); // npm install --save-dev load-grunt-tasks

grunt.initConfig({
    recess: {
        dist: {
            src: ['src/main.css']
        }
    }
});

grunt.registerTask('default', ['recess']);

Lint and compile

recess: {
    dist: {
        options: {
            compile: true
        },
        files: {
            'dist/main.css': 'src/main.less'
        }
    }
}

A destination is only needed when compile: true. It won't output any warnings in this mode. You can also specify .less files and they will be compiled.

Options

// Default
compile: false              // Compiles CSS or LESS. Fixes white space and sort order.
compress: false             // Compress your compiled code
noIDs: true                 // Doesn't complain about using IDs in your stylesheets
noJSPrefix: true            // Doesn't complain about styling .js- prefixed classnames
noOverqualifying: true      // Doesn't complain about overqualified selectors (ie: div#foo.bar)
noUnderscores: true         // Doesn't complain about using underscores in your class names
noUniversalSelectors: true  // Doesn't complain about using the universal * selector
prefixWhitespace: true      // Adds whitespace prefix to line up vender prefixed properties
strictPropertyOrder: true   // Complains if not strict property order
zeroUnits: true             // Doesn't complain if you add units to values of 0
includePath: mixed          // Additional paths to look for `@import`'ed LESS files.  Accepts a string or an array of strings.

License

MIT © Sindre Sorhus