eslint-config-chasevida
v1.0.0
Published
Shareable ESLint config
Downloads
76
Maintainers
Readme
eslint-config-chasevida
A pretty common ESLint config setup that can be shared around. To get this working you simply install this via npm then add the followingn to your ESLint config file.
Note: This ESLint config is essentially a fork from eslint-config-hapi. Those devs are ace so best stick with theirs, this is just for a few styling differences that my team prefers.
Install
npm install --save-dev eslint-config-chasevida
Use
In your .eslintrc.js
file add the following:
{
"extends": "chasevida"
}
Contributing
If you are submitting a PR to add or change an existing rule please make sure you run $ npm run docs
to re-generate the README.md
with the updated rule list. As a rule of thumb it should be one commit per rule for easy reference for changes.
SemVer?
Changes that are breaking e.g. upgrading from a warning to an exception should be a major bump. Downgrading to a warning should be a minor bump. Anything else related to a warning (say changing some config) could just be a patch I guess. Suggestions welcome on better ways to version this... could use a date based system¿?
Rules
- array-bracket-spacing: [ 2, "never" ]
- arrow-parens: [ 2, "always" ]
- arrow-spacing: [ 2, { "before": true, "after": true } ]
- brace-style: [ 2, "stroustrup" ]
- callback-return: [ 2, [ "callback", "next" ] ]
- camelcase: 2
- chasevida/spaces-in-parens: [ 1, "never", { "exceptions": [ "!" ] } ]
- comma-dangle: [ 2, "never" ]
- computed-property-spacing: [ 2, "never" ]
- consistent-return: 2
- consistent-this: [ 2, "self" ]
- constructor-super: 2
- curly: [ 2, "all" ]
- dot-notation: 1
- eol-last: 1
- eqeqeq: 2
- func-style: [ 2, "expression" ]
- generator-star-spacing: [ 2, { "before": true, "after": false } ]
- global-strict: 0
- handle-callback-err: [ 2, "err" ]
- hapi/hapi-capitalize-modules: 1
- hapi/no-arrowception: 1
- indent: [ 2, 4 ]
- key-spacing: 2
- keyword-spacing: 2
- max-depth: [ 2, 5 ]
- max-nested-callbacks: [ 2, 3 ]
- max-params: [ 1, 4 ]
- new-cap: 2
- new-parens: 2
- newline-after-var: 0
- no-array-constructor: 2
- no-class-assign: 2
- no-console: 1
- no-constant-condition: 2
- no-else-return: 2
- no-empty: 2
- no-eq-null: 2
- no-eval: 2
- no-ex-assign: 2
- no-extend-native: [ 2, { "exceptions": [ "Object" ] } ]
- no-lonely-if: 2
- no-loop-func: 2
- no-mixed-requires: 2
- no-mixed-spaces-and-tabs: 2
- no-multi-spaces: [ 2 ]
- no-native-reassign: 2
- no-new-object: 2
- no-new-require: 2
- no-new-wrappers: 2
- no-path-concat: 2
- no-process-exit: 2
- no-redeclare: 2
- no-regex-spaces: 2
- no-return-assign: 2
- no-shadow: 2
- no-sparse-arrays: 2
- no-this-before-super: 2
- no-trailing-spaces: 1
- no-undef: 2
- no-underscore-dangle: 2
- no-unreachable: 2
- no-unused-expressions: 2
- no-unused-vars: 1
- no-use-before-define: [ 1, "nofunc" ]
- no-useless-call: 1
- no-with: 2
- object-curly-spacing: [ 2, "never" ]
- object-shorthand: 1
- one-var: 0
- quotes: [ 2, "single", "avoid-escape" ]
- radix: 2
- semi: [ 1, "never" ]
- sort-vars: 0
- space-before-function-paren: [ 2, "always" ]
- space-infix-ops: 2
- space-unary-ops: [ 1, { "words": true, "nonwords": true } ]
- vars-on-top: 0
- wrap-iife: [ 2, "inside" ]
- yoda: [ 1, "never" ]