lesshint-extra-webpack-plugin

0.0.2 • Public • Published

Lesshint Plugin for Webpack

npm

Install

$ npm install lesshint-extra-webpack-plugin

Usage

In your webpack configuration:

const LessHintPlugin = require('lesshint-extra-webpack-plugin');
 
module.exports = {
  // ...
  plugins: [
    new LessHintPlugin({
          files: [
              './source/applications/**/*.less',
              '!./vendor/**/*.less'
          ],
          configFile: path.resolve(__dirname, '.lesshintrc')
      })
  ],
  // ...
}

For using additional linters:

const LessHintPlugin = require('lesshint-extra-webpack-plugin');
 
module.exports = {
  // ...
  plugins: [
    new LessHintPlugin({
          files: [
              './source/applications/**/*.less',
              '!./vendor/**/*.less'
          ],
          configFile: path.resolve(__dirname, '.lesshintrc'),
          linters : [
              require('./source/my-awesome-linter')
          ]
      })
  ],
  // ...
}

Options

See lesshint options, for the complete list of options.

  • configFile: The config file location for your lesshint options.
  • files: The glob pattern for finding files.
  • linters: Additional linters to be used by lesshint.
  • reporter: The reporter for lesshint. Default: lesshint-reporter-stylish.
  • failOnError : If webpack build should fail if lesshint reported errors. Default: false.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.2
    3
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.2
    3
  • 0.0.1
    2

Package Sidebar

Install

npm i lesshint-extra-webpack-plugin

Weekly Downloads

4

Version

0.0.2

License

MIT

Last publish

Collaborators

  • xtephan