0.1.0 • Published 7 years ago

stylelint-brunch v0.1.0

Weekly downloads
2
License
Apache-2.0
Repository
github
Last release
7 years ago

stylelint-brunch

Adding Stylelint support to brunch. CircleCI

installation

Install the plugin via npm:

npm i -D stylelint-brunch

configuration

There is no needed configuration. If you install this package it will attempt the standard lookup for a style-lint file and lint all css files. This assumes you have CSS files and want to use your system lint configuration.

pattern

For SASS, you can use this configuration:

config = {
  stylelint: {
    pattern: '^app[\\\/\\\\].*\\\.scss?$'
  }
}

The pattern parameter is evaluated in a new RegExp() call if it's a string. Change the pattern to match your desired file type.

warnOnly

Passing a warnOnly key allows you to prevent errors from being thrown. This defaults to true.

config = {
  stylelint: {
    warnOnly: false
  }
}

formatter

Passing a formatter key allows you to select your preferred formatter. This defaults to string.

config = {
  stylelint: {
    formatter: 'json'
  }
}

config

Passing any valid stylelint options here are supported and override ad you'd expect.

config = {
  stylelint: {
    config: {
      // whatever you want to pass that's valid stylelint options.
    }
  }
}

license

Licensed under the Apache-2.0 license.

shout out

Thanks @mirko-lelansky, this is extended from his base project.

todo

Add some decent tests