Open arreche opened 8 years ago
When eslint
detects any errors, it will exit with non zero status. Right now, if there is an error with eslint
, npm
will also error. Si it looks like eslint isn't working correctly. Running eslint public test || true
or npm run lint --silent
will hide npm errors.
I actually don't care if npm
shows its own errors, but others might get confused.
Also, if any one is running npm version 3 or greater, it doesn't install peer dependencies automatically. So npm run lint
will break.
Right now it looks like the current airbnb config is for ES6. You might have to switch to eslint-config-airbnb-base
package and use airbnb-base/legacy
in eslint.js
to lint ES5. Also, adding another package to suppress jasmine errors would nice (errors for describe
and expect
).
I have some things I realized while I was running the linter.
.eslintrc.js
with jasmine plugin in the test/
directory and remove jamine plugin from .eslintrc.js
in root directory. This way, jasmine plugin only applies in the test/
directory. You can read more about this in Configuration Cascading and Hierarchyindex_spec.js
). We might have to turn off no-undef
rule in the test/
directory. You can use the config file or inline comment for this.Everything looks good. You should merge it once another person takes a look.
Run it with:
npm run lint