-
Notifications
You must be signed in to change notification settings - Fork 3
/
.eslintrc.extension.json
93 lines (93 loc) · 2.85 KB
/
.eslintrc.extension.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
81
82
83
84
85
86
87
88
89
90
91
92
93
{
"root": true,
"env": {
"node": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:import/typescript"
],
"settings": {
"import/resolver": {
"typescript": {
"project": "tsconfig.extension.json"
},
"webpack": {
"config": "webpack.config.ts",
"config-index": 0
}
},
"import/extensions": [".js", ".ts"]
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 12,
"sourceType": "module"
},
"plugins": [
"@typescript-eslint"
],
"rules": {
"import/no-extraneous-dependencies": "off",
"max-len": ["error", {
"code": 120,
"ignorePattern": "^import\\s.+\\sfrom\\s.+;$",
"ignoreRegExpLiterals": true,
"ignoreTemplateLiterals": true,
"ignoreStrings": true
}],
"indent": ["warn", 4, { "SwitchCase": 1 }],
"linebreak-style": "off",
"quotes": ["error", "single"],
"semi": ["error", "always"],
"object-curly-spacing": ["warn", "always", {
"objectsInObjects": true,
"arraysInObjects": false
}],
"curly": [1, "multi-line"],
"no-eq-null": "off",
"eqeqeq": ["error", "smart"],
"padding-line-between-statements": [
"error",
{ "blankLine": "never", "prev": "block-like", "next": "case" },
{ "blankLine": "never", "prev": "block-like", "next": "default" }
],
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": ["error", {
"varsIgnorePattern": "NodeCGBrowser"
}],
"no-empty": ["error", { "allowEmptyCatch": true }],
"@typescript-eslint/ban-ts-comment": ["error", {
"ts-ignore": "allow-with-description"
}],
"space-before-blocks": ["error"],
"keyword-spacing": ["error"],
"@typescript-eslint/type-annotation-spacing": [
"error",
{
"before": false,
"after": true,
"overrides": {
"arrow": {
"before": true,
"after": true
}
}
}
],
"operator-linebreak": ["error", "before"],
"quote-props": [2, "as-needed", {"numbers": true}]
},
"overrides": [
{
"files": ["*.test.ts", "__mocks__/*.ts"],
"rules": {
"@typescript-eslint/no-var-requires": 0,
"@typescript-eslint/no-this-alias": 0,
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/no-explicit-any": "off"
}
}
]
}