forked from router5/router5
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc
69 lines (69 loc) · 1.71 KB
/
.eslintrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
{
"extends": [
"eslint:recommended"
],
// Parser
"parser": "babel-eslint",
"plugins": [
"react"
],
// ECMA Features
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"arrowFunctions": true,
"blockBindings": true,
"classes": true,
"defaultParams": true,
"destructuring": true,
"modules": true,
"objectLiteralComputedProperties": true,
"templateStrings": true,
"jsx": true
}
},
"rules": {
// Possible Errors
"no-dupe-args": 2,
"no-dupe-keys": 2,
"no-empty": 2,
"no-func-assign": 2,
"no-inner-declarations": 2,
"no-unreachable": 2,
"no-unexpected-multiline": 2,
// Best practices
"consistent-return": 0,
"eqeqeq": 2,
"no-else-return": 2,
"no-multi-spaces": 0,
"no-console": ["error", { "allow": ["warn", "error"] }],
// Strict mode
"strict": 0,
// Variables
"no-shadow": 0,
"no-unused-vars": 2,
"no-use-before-define": 0,
// Style
"consistent-this": [2, "that"],
"key-spacing": 0,
"new-parens": 0,
"no-extra-semi": 0,
"no-mixed-spaces-and-tabs": 0,
"no-underscore-dangle": 0,
"no-unneeded-ternary": 2,
// ES6
"no-var": 2,
"no-this-before-super": 2,
"object-shorthand": 2,
// React
"react/jsx-uses-react": 2,
"react/jsx-uses-vars": 2,
"react/react-in-jsx-scope": 2
},
"env": {
"node": true,
"browser": true,
"mocha": true
}
}