-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.json
119 lines (119 loc) · 3.79 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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
{
"extends": [
"eslint:recommended",
".eslintrc.base.json"
],
"env": {
"node": true,
"es6": true,
"mocha": true
},
"parserOptions": {
"ecmaVersion": 9,
"sourceType": "script"
},
"root": true,
"rules": {
"array-type": "off",
"trailing-comma": "off",
"no-trailing-whitespace": "off",
"object-literal-sort-keys": "off",
"object-literal-key-quotes": "off",
"no-default-export": "off",
"no-var-requires": "off",
"variable-name": "off",
"interface-name": "off",
"max-line-length": "off",
"curly": "off",
"no-console": "off",
"no-consecutive-blank-lines": "off",
"interface-over-type-literal": "off",
"no-namespace": "off",
"ordered-imports": "off",
"prefer-rest-params": "warn",
"no-extra-boolean-cast": "warn"
},
"overrides": [
{
"files": ["**/*.ts", "**/*.tsx"],
"extends": [
"plugin:@typescript-eslint/recommended",
".eslintrc.ts.json"
],
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint"],
"rules": {
"@typescript-eslint/no-explicit-any": ["warn", { "ignoreRestArgs": true, "fixToUnknown": false }],
"@typescript-eslint/naming-convention": [
"error",
{
"selector": "default",
"format": ["camelCase"],
"leadingUnderscore": "forbid",
"trailingUnderscore": "forbid"
},
{
"selector": "variable",
"modifiers": ["global", "const"],
"format": ["camelCase", "UPPER_CASE", "PascalCase"]
},
{
"selector": "function",
"format": ["camelCase"]
},
{
"selector": "property",
"modifiers": ["private"],
"leadingUnderscore": "require",
"format": ["camelCase"]
},
{
"selector": "parameter",
"leadingUnderscore": "allow",
"format": ["camelCase"]
},
{
"selector": "parameterProperty",
"modifiers": ["private"],
"leadingUnderscore": "require",
"format": ["camelCase"]
},
{
"selector": "class",
"modifiers": ["abstract"],
"prefix": ["Abstract"],
"format": ["PascalCase"]
},
{
"selector": "class",
"format": ["PascalCase"]
},
{
"selector": "enum",
"format": ["PascalCase"]
},
{
"selector": "interface",
"format": ["PascalCase"]
},
{
"selector": "typeParameter",
"format": ["camelCase", "PascalCase"]
},
{
"selector": "typeAlias",
"format": ["PascalCase"]
},
{
"selector": "enumMember",
"format": ["PascalCase"]
},
{
"selector": "objectLiteralProperty",
"format": null
}
]
}
}
]
}