Skip to content

Commit

Permalink
Merge pull request #29 from billybonks/enhancement/improve-options
Browse files Browse the repository at this point in the history
Enhancement/improve options
  • Loading branch information
billybonks authored Sep 8, 2016
2 parents 0c575a7 + 5dae877 commit fa1b085
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 4 deletions.
19 changes: 19 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,25 @@ An Ember-CLI addon that allows easy integration with [stylelint](http://stylelin

`ember install ember-cli-stylelint`

##Syntax
By default syntax is `scss`, if you want to use another one you need to configure the option in your `ember-cli-build`

```javascript
var app = new EmberApp(defaults, {
stylelint: {
linterConfig:{
syntax: 'less'
},
}
});
```

You can use one of the following values for `syntax`
- scss
- css
- less
- sugarss

##Configuration

Linting configuration can be added in a
Expand Down
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ module.exports = {

included: function(app) {
//shared
this.styleLintOptions = app.options.styleLint || {generateTests:true};
this.styleLintOptions = app.options.stylelint || {};
this.styleLintOptions.console = console;

//used in real app only
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
],
"dependencies": {
"broccoli-funnel": "^1.0.1",
"broccoli-stylelint": "^0.7.0",
"broccoli-stylelint": "^0.8.0",
"ember-cli-babel": "^5.1.5"
},
"ember-addon": {
Expand Down
3 changes: 1 addition & 2 deletions tests/runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,10 @@ function buildAndLint(sourcePath) {
linter.included({
isTestingStyleLintAddon: true,
options: {
styleLint:{
stylelint:{
onError: function(results) {
errors.push(results);
},
generateTests:true,
console:console
}
},
Expand Down

0 comments on commit fa1b085

Please sign in to comment.