-
Notifications
You must be signed in to change notification settings - Fork 4
/
.eslintrc.js
69 lines (65 loc) · 1.8 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
61
62
63
64
65
66
67
68
69
const OFF = 0, WARN = 1, ERROR = 2;
module.exports = {
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint", "fp"],
"env": { "browser": true, "node": true },
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"rules": {
/* typescript */
"@typescript-eslint/member-delimiter-style": ["off", {
"multiline": {
"delimiter": "semi",
"requireLast": false
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}],
/* functional */
"fp/no-arguments": "warn",
//"fp/no-class": "warn",
"fp/no-delete": "warn",
"fp/no-events": "warn",
"fp/no-get-set": "warn",
"fp/no-let": "warn",
"fp/no-loops": "warn",
"fp/no-mutating-assign": "warn",
"fp/no-mutating-methods": "warn",
"fp/no-mutation": "warn",
//"fp/no-nil": "warn",
"fp/no-proxy": "warn",
"fp/no-rest-parameters": "warn",
//"fp/no-this": "warn",
//"fp/no-throw": "warn",
//"fp/no-unused-expression": "warn",
"fp/no-valueof-field": "warn",
/* general */
"no-var": "warn",
"no-console": "off",
//"no-unused-vars": "error",
"no-unused-expressions": "error",
"no-unused-labels": "error",
"no-await-in-loop": "error",
"no-irregular-whitespace": "error",
"no-unexpected-multiline": "error",
"no-template-curly-in-string": "error",
"no-unsafe-negation": "error",
"require-atomic-updates": "error",
"no-import-assign": "error",
"no-unreachable": "error",
"init-declarations": ["error", "always"],
"no-shadow": "error",
"no-undef-init": "off",
/* code style */
"semi": ["error", "never"],
"brace-style": ["error", "stroustrup"],
"camelcase": ["error", { "properties": "always", "ignoreImports": true }],
"block-spacing": ["error", "always"],
//"indent": ["warn", "tab"]
}
}