add .eslintrc
This commit is contained in:
parent
e394f5f068
commit
bb96954e69
1 changed files with 43 additions and 0 deletions
43
.eslintrc
Normal file
43
.eslintrc
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
{
|
||||||
|
"env": {
|
||||||
|
"es6": true,
|
||||||
|
"node" : true,
|
||||||
|
"browser" : true
|
||||||
|
},
|
||||||
|
"parser": "babel-eslint",
|
||||||
|
"parserOptions": {
|
||||||
|
"ecmaFeatures": {
|
||||||
|
"jsx": true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"extends": [ "eslint:recommended" ],
|
||||||
|
"rules": {
|
||||||
|
"arrow-body-style": "off",
|
||||||
|
"brace-style": ["error", "1tbs", { "allowSingleLine": true }],
|
||||||
|
"id-length": "off",
|
||||||
|
"indent": ["error", 2],
|
||||||
|
"newline-after-var": "off",
|
||||||
|
"newline-before-return": "off",
|
||||||
|
"multiline-ternary": "off",
|
||||||
|
"max-statements": ["error", 15],
|
||||||
|
"no-console": ["error", { allow: ["warn", "error"] }],
|
||||||
|
"no-magic-numbers": ["error", { "ignore": [0, 1, 2] }],
|
||||||
|
"no-param-reassign": "off",
|
||||||
|
"no-ternary": "off",
|
||||||
|
"object-curly-spacing": [
|
||||||
|
"error",
|
||||||
|
"always", { "arraysInObjects": false, "objectsInObjects": false }
|
||||||
|
],
|
||||||
|
"object-curly-newline": "off",
|
||||||
|
"object-property-newline": "off",
|
||||||
|
"object-shorthand": "off",
|
||||||
|
"padded-blocks": "off",
|
||||||
|
"prefer-template": "off",
|
||||||
|
"quote-props": ["error", "as-needed"],
|
||||||
|
"require-jsdoc": "off",
|
||||||
|
"sort-imports": "off",
|
||||||
|
"sort-keys": "off",
|
||||||
|
"sort-vars": "off",
|
||||||
|
"space-before-function-paren": ["error", "never"]
|
||||||
|
}
|
||||||
|
}
|
Reference in a new issue