-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
80 lines (75 loc) · 1.97 KB
/
.eslintrc.json
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
70
71
72
73
74
75
76
77
78
79
80
{
"extends": "eslint:recommended",
"parserOptions": {
"ecmaFeatures": {
// node 5.1 features
"arrowFunctions": true,
"blockBindings": true,
"classes": true,
"forOf": true,
"generators": true,
"spread": true,
"superInFunctions": false
},
},
"env": {
"node": true,
"es6": true
},
"rules": {
// best practices
"eqeqeq": 2,
"curly": 2,
"consistent-return": 2,
"no-extra-bind": 2,
"no-eval": 2,
"no-implied-eval": 2,
"no-loop-func": 2,
"no-magic-numbers": 1,
"no-native-reassign": 2,
"no-new-func": 2,
"no-redeclare": 2,
"no-useless-call": 2,
"vars-on-top": 1,
// strict mode
"strict": [2, "global"],
// variables
"init-declarations": 2,
"no-delete-var": 2,
"no-shadow": 1,
"no-undef-init": 2,
"no-unused-vars": 2,
"no-use-before-define": 2,
// nodejs
"handle-callback-err": [2, "^(err|error)$"],
"no-process-exit": 2,
// style
"block-spacing": 2,
"brace-style": 2,
"camelcase": 2,
"indent": 2,
"keyword-spacing": 2,
"linebreak-style": 2,
"max-len": [2, 120],
"no-mixed-spaces-and-tabs": 2,
"no-nested-ternary": 2,
"quotes": [2, "single"],
"require-jsdoc": 2,
"semi": [2, "always"],
"space-before-blocks": 2,
// es6
"arrow-body-style": [2, "as-needed"],
"arrow-spacing": 2,
"constructor-super": 2,
"no-class-assign": 2,
"no-confusing-arrow": 2,
"no-const-assign": 2,
"no-constant-condition": 2,
"no-dupe-class-members": 2,
"no-this-before-super": 2,
"no-var": 2,
"prefer-arrow-callback": 1,
"prefer-spread": 2,
"require-yield": 2
}
}