Skip to content

Instantly share code, notes, and snippets.

@alex-page
Last active April 7, 2018 02:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alex-page/2ea2649ede1ec72c520efb463e83dce0 to your computer and use it in GitHub Desktop.
Save alex-page/2ea2649ede1ec72c520efb463e83dce0 to your computer and use it in GitHub Desktop.
AirBNB ESLint with more human readable spacing
# You should `npm i eslint eslint-config-airbnb-base eslint-plugin-import --save-dev`
extends: airbnb-base
rules:
max-len:
- error
- code: 120 # Code max length
comments: 120
tabWidth: 2
ignoreUrls: true
indent:
- error
- tab
no-tabs: off
space-in-parens:
- error
- always
- exceptions: [ "{}" ]
template-curly-spacing:
- error
- always
brace-style:
- error
- stroustrup
keyword-spacing:
- error
- overrides:
if:
after: false
while:
after: false
for:
after: false
catch:
after: false
throw:
after: false
computed-property-spacing:
- error
- always
array-bracket-spacing:
- error
- always
key-spacing:
- error
- align: "value"
require-jsdoc:
- error
- require:
FunctionDeclaration: true
MethodDefinition: true
ClassDeclaration: true
ArrowFunctionExpression: true
FunctionExpression: true
valid-jsdoc:
- error
- requireReturn: false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment