This repository has been archived by the owner on May 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
60 lines (59 loc) · 1.68 KB
/
.eslintrc.js
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
module.exports = {
env: {
es6: true,
browser: true
},
plugins: [
"fp",
"better",
"import"
],
extends: [
"eslint:recommended",
"plugin:fp/recommended",
"plugin:import/errors",
"plugin:import/warnings"
],
rules: {
// eslint:recommended
"comma-spacing": ["error", {before: false, after: true}],
"comma-style": ["error", "last"],
"eqeqeq": "error",
"indent": ["error", 2, {SwitchCase: 1}],
"key-spacing": ["error", {beforeColon: false, afterColon: true}],
"keyword-spacing": ["error", {before: true, after: true}],
"no-unused-vars": "off", // handled by eslint-plugin-fp
// eslint-plugin-better
"better/no-ifs": "error",
"better/no-new": "error",
"better/no-instanceofs": "error",
"better/explicit-return": "error",
// following rules are handled by eslint-plugin-fp
"better/no-deletes": "off",
"better/no-exceptions": "off",
"better/no-classes": "off",
"better/no-exports": "off",
"better/no-fors": "off",
"better/no-function-expressions": "off",
"better/no-imports": "off",
"better/no-nulls": "off",
"better/no-reassigns": "off",
"better/no-switches": "off",
"better/no-this": "off",
"better/no-typeof": "off",
"better/no-undefined": "off",
"better/no-variable-declaration": "off",
"better/no-whiles": "off",
// eslint-plugin-import
"import/no-extraneous-dependencies": "error",
"import/no-absolute-path": "error",
"import/no-mutable-exports": "error",
"import/no-commonjs": "error",
"import/no-amd": "error",
"import/no-nodejs-modules": "error"
},
parserOptions: {
ecmaVersion: 6,
sourceType: "module"
}
};