1
-
2
1
{
3
- "env": {
4
- "node": true
5
- },
6
- "rules": {
7
- "quotes": 0
8
- }
9
- }
2
+
3
+ "parser": "babel-eslint",
4
+
5
+ "env": {
6
+ "browser": false,
7
+ "node": true,
8
+ "amd": true,
9
+ "mocha": true,
10
+ "es6": true
11
+ },
12
+
13
+ "ecmaFeatures": {
14
+ "modules": true
15
+ },
16
+
17
+ "parserOptions": {
18
+ "sourceType": "module"
19
+ },
20
+
21
+ "globals": {
22
+ "window": true,
23
+ "document": true,
24
+ "Promise": false
25
+ },
26
+
27
+ "fix": true,
28
+
29
+ "rules": {
30
+ // possible errors
31
+ "comma-dangle": 2,
32
+ "no-cond-assign": 2,
33
+ "no-console": 0,
34
+ "no-constant-condition": 0,
35
+ "no-control-regex": 2,
36
+ "no-debugger": 2,
37
+ "no-dupe-args": 0,
38
+ "no-dupe-keys": 2,
39
+ "no-duplicate-case": 0,
40
+ "no-empty-character-class": 2,
41
+ "no-empty": 2,
42
+ "no-ex-assign": 2,
43
+ "no-extra-boolean-cast": 2,
44
+ "no-extra-parens": 0,
45
+ "no-extra-semi": 2,
46
+ "no-func-assign": 2,
47
+ "no-inner-declarations": [2, "functions"],
48
+ "no-invalid-regexp": 2,
49
+ "no-irregular-whitespace": 0,
50
+ "no-negated-in-lhs": 2,
51
+ "no-obj-calls": 2,
52
+ "no-regex-spaces": 2,
53
+ "no-sparse-arrays": 2,
54
+ "no-unexpected-multiline": 0,
55
+ "no-unreachable": 2,
56
+ "use-isnan": 2,
57
+ "valid-jsdoc": 0,
58
+ "valid-typeof": 2,
59
+
60
+ // best practices
61
+ "accessor-pairs": 0,
62
+ "array-callback-return": 2,
63
+ "block-scoped-var": 2,
64
+ "complexity": [0, 10], // would love to turn this on someday
65
+ "consistent-return": 0,
66
+ "curly": [2, "all"],
67
+ "default-case": 2,
68
+ "dot-location": 0,
69
+ "dot-notation": 2,
70
+ "eqeqeq": 2,
71
+ "guard-for-in": 0,
72
+ "no-alert": 2,
73
+ "no-caller": 2,
74
+ "no-case-declarations": 0,
75
+ "no-div-regex": 2,
76
+ "no-else-return": 0,
77
+ "no-empty-function": 1,
78
+ "no-empty-pattern": 0,
79
+ "no-eq-null": 2,
80
+ "no-eval": 2,
81
+ "no-extend-native": 2,
82
+ "no-extra-bind": 2,
83
+ "no-extra-label": 2,
84
+ "no-fallthrough": 2,
85
+ "no-floating-decimal": 2,
86
+ "no-implicit-coercion": 0,
87
+ "no-implicit-globals": 2,
88
+ "no-implied-eval": 2,
89
+ "no-invalid-this": 0,
90
+ "no-iterator": 2,
91
+ "no-labels": 2,
92
+ "no-lone-blocks": 2,
93
+ "no-loop-func": 2,
94
+ "no-magic-numbers": 0,
95
+ "no-multi-spaces": 2,
96
+ "no-multi-str": 2,
97
+ "no-native-reassign": 2,
98
+ "no-new-func": 2,
99
+ "no-new-wrappers": 2,
100
+ "no-new": 2,
101
+ "no-octal-escape": 2,
102
+ "no-octal": 2,
103
+ "no-param-reassign": 0,
104
+ "no-process-env": 0,
105
+ "no-proto": 2,
106
+ "no-redeclare": 2,
107
+ "no-return-assign": 2,
108
+ "no-script-url": 2,
109
+ "no-self-assign": 2,
110
+ "no-self-compare": 2,
111
+ "no-sequences": 2,
112
+ "no-throw-literal": 2,
113
+ "no-unmodified-loop-condition": 2,
114
+ "no-unused-expressions": 2,
115
+ "no-unused-labels": 2,
116
+ "no-useless-call": 0,
117
+ "no-useless-concat": 0,
118
+ "no-void": 2,
119
+ "no-warning-comments": 0,
120
+ "no-with": 2,
121
+ "radix": 2,
122
+ "vars-on-top": 0,
123
+ "wrap-iife": 2,
124
+ "yoda": 2,
125
+
126
+ // strict
127
+ "strict": [2, "global"],
128
+
129
+ // variables
130
+ "init-declarations": 0,
131
+ "no-catch-shadow": 2,
132
+ "no-delete-var": 2,
133
+ "no-label-var": 2,
134
+ "no-restricted-globals": 0,
135
+ "no-shadow-restricted-names": 2,
136
+ "no-shadow": 2,
137
+ "no-undef-init": 2,
138
+ "no-undef": 2,
139
+ "no-undefined": 0,
140
+ "no-unused-vars": [2, {"vars": "all", "args": "none"}],
141
+ "no-use-before-define": 1,
142
+
143
+ // node.js
144
+ "callback-return": 0,
145
+ "global-require": 0,
146
+ "handle-callback-err": 2,
147
+ "no-mixed-requires": 2,
148
+ "no-new-require": 2,
149
+ "no-path-concat": 2,
150
+ "no-process-exit": 2,
151
+ "no-restricted-modules": 0,
152
+ "no-sync": 2,
153
+
154
+ // stylistic issues
155
+ "array-bracket-spacing": 0,
156
+ "block-spacing": 0,
157
+ "brace-style": 0,
158
+ "camelcase": 0,
159
+ "comma-spacing": [2, {"before": false, "after": true}],
160
+ "comma-style": [1, "last"],
161
+ "computed-property-spacing": 0,
162
+ "consistent-this": [2, "self"],
163
+ "eol-last": 0,
164
+ "func-names": 0,
165
+ "func-style": [0, "declaration"],
166
+ "id-blacklist": 0,
167
+ "id-length": 0,
168
+ "id-match": 0,
169
+ "indent": [2, 4, {"SwitchCase": 1}],
170
+ "jsx-quotes": 0,
171
+ "key-spacing": 0,
172
+ "keyword-spacing": 2,
173
+ "linebreak-style": 0,
174
+ "lines-around-comment": 0,
175
+ "max-depth": [0, 4],
176
+ "max-len": [0, 80, 4],
177
+ "max-nested-callbacks": [0, 2],
178
+ "max-params": [1, 5],
179
+ "max-statements": [1, 30],
180
+ "new-cap": 2,
181
+ "new-parens": 2,
182
+ "newline-after-var": 0,
183
+ "newline-before-return": 0,
184
+ "newline-per-chained-call": 0,
185
+ "no-array-constructor": 2,
186
+ "no-bitwise": 2,
187
+ "no-continue": 0,
188
+ "no-inline-comments": 0,
189
+ "no-lonely-if": 2,
190
+ "no-mixed-spaces-and-tabs": [2, true],
191
+ "no-multiple-empty-lines": 0,
192
+ "no-negated-condition": 0,
193
+ "no-nested-ternary": 2,
194
+ "no-new-object": 2,
195
+ "no-plusplus": 0,
196
+ "no-restricted-syntax": 0,
197
+ "no-spaced-func": 2,
198
+ "no-ternary": 0,
199
+ "no-trailing-spaces": 0,
200
+ "no-underscore-dangle": 0,
201
+ "no-unneeded-ternary": 0,
202
+ "no-whitespace-before-property": 2,
203
+ "object-curly-spacing": 0,
204
+ "one-var": 0,
205
+ "one-var-declaration-per-line": [1, "always"],
206
+ "operator-assignment": 0,
207
+ "operator-linebreak": 0,
208
+ "padded-blocks": 0,
209
+ "quote-props": 0,
210
+ "quotes": [2, "single"],
211
+ "require-jsdoc": 0,
212
+ "semi-spacing": 2,
213
+ "semi": 2,
214
+ "sort-imports": 0,
215
+ "sort-vars": 0,
216
+ "space-before-blocks": [2, "always"],
217
+ "space-before-function-paren": 0,
218
+ "space-in-parens": 2,
219
+ "space-infix-ops": 2,
220
+ "space-unary-ops": [2, { "words": true, "nonwords": false }],
221
+ "spaced-comment": 2,
222
+ "wrap-regex": 2,
223
+
224
+ // ES6
225
+
226
+ // require braces in arrow function body
227
+ "arrow-body-style": 0,
228
+ // require parens in arrow function arguments
229
+ "arrow-parens": 0,
230
+ // require space before/after arrow function's arrow
231
+ "arrow-spacing": 2,
232
+ // verify super() callings in constructors
233
+ "constructor-super": 2,
234
+ // enforce the spacing around the * in generator functions
235
+ "generator-star-spacing": 0,
236
+ // disallow modifying variables of class declarations
237
+ "no-class-assign": 2,
238
+ "no-confusing-arrow": 2,
239
+ // disallow modifying variables that are declared using const
240
+ "no-const-assign": 2,
241
+ // disallow duplicate name in class members
242
+ "no-dupe-class-members": 2,
243
+ "no-new-symbol": 2,
244
+ "no-restricted-imports": 0,
245
+ // disallow to use this/super before super() calling in constructors.
246
+ "no-this-before-super": 2,
247
+ "no-useless-constructor": 2,
248
+ // require let or const instead of var
249
+ "no-var": 1,
250
+ // require method and property shorthand syntax for object literals
251
+ "object-shorthand": 1,
252
+ // suggest using arrow functions as callbacks
253
+ "prefer-arrow-callback": 1,
254
+ // suggest using of const declaration for variables that are never modified after declared
255
+ "prefer-const": 0,
256
+ "prefer-rest-params": 0,
257
+ // suggest using Reflect methods where applicable
258
+ "prefer-reflect": 0,
259
+ // suggest using the spread operator instead of .apply()
260
+ "prefer-spread": 0,
261
+ // suggest using template literals instead of strings concatenation
262
+ "prefer-template": 2,
263
+ // disallow generator functions that do not have yield
264
+ "require-yield": 2,
265
+ "template-curly-spacing": 0,
266
+ "yield-star-spacing": 0
267
+ }
268
+
269
+ }
0 commit comments