Skip to content

Instantly share code, notes, and snippets.

@belchior
Last active March 4, 2018 23:58
Show Gist options
  • Save belchior/c35032606d85dbad774c to your computer and use it in GitHub Desktop.
Save belchior/c35032606d85dbad774c to your computer and use it in GitHub Desktop.
Eslint rules
{
"env": {
"browser": true,
"es6": true
},
"extends": [
"eslint:recommended"
],
"parserOptions": {
"sourceType": "module",
"ecmaVersion": 2017,
"ecmaFeatures": {
"experimentalObjectRestSpread": true
}
},
"rules": {
"brace-style": [2],
"camelcase": [2],
"comma-style": [2, "last"],
"curly": [2],
"eol-last": [2],
"eqeqeq": [2],
"indent": [2, 2, {"SwitchCase": 1}],
"key-spacing": [2],
"linebreak-style": [2, "unix"],
"max-len": [2, 300, 4],
"new-cap": [2, {"newIsCap": true, "capIsNew": true}],
"new-parens": [2],
"no-cond-assign": [2],
"no-duplicate-case": [2],
"no-eval": [2],
"no-extra-semi": [2],
"no-implicit-coercion": [2, {"boolean": true, "number": true, "string": true}],
"no-inner-declarations": [2, "both"],
"no-mixed-spaces-and-tabs": [2],
"no-multiple-empty-lines": [2, {"max": 2}],
"no-multi-spaces": [2],
"no-multi-str": [2],
"no-redeclare": [2, {"builtinGlobals": true}],
"no-shadow": [2],
"no-spaced-func": [2],
"no-throw-literal": [2],
"no-trailing-spaces": [2],
"no-unneeded-ternary": [2],
"no-unreachable": [2],
"no-with": [2],
"one-var": [2, "never"],
"operator-linebreak": [2, "after"],
"quotes": [2, "single"],
"semi": [2, "always"],
"semi-spacing": [2],
"spaced-comment": [2, "always"],
"keyword-spacing": [2],
"space-before-blocks": [2, "always"],
"space-before-function-paren": [2, {"anonymous": "always", "named": "never"}],
"space-in-parens": [2, "never"],
"space-unary-ops": [2, {"words": true, "nonwords": false}],
"valid-typeof": [2],
"vars-on-top": [2],
"yoda": [2, "never"],
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment