-
Notifications
You must be signed in to change notification settings - Fork 2
/
.eslintrc.json
126 lines (126 loc) · 3.67 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
120
121
122
123
124
125
126
{
"root": true,
"env": {
"node": true,
"browser": false,
"es6": true
},
"ignorePatterns": ["dist/"],
"extends": [
"eslint:recommended"
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 2021,
"sourceType": "module"
},
"overrides": [{
"files": ["**.ts"],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint",
"import",
"node"
],
"rules": {
"@typescript-eslint/explicit-module-boundary-types": ["off"],
"@typescript-eslint/ban-ts-comment": ["off"],
"@typescript-eslint/no-explicit-any": ["off"],
"semi": ["off"],
"@typescript-eslint/semi": ["warn", "always"],
"@typescript-eslint/no-inferrable-types": ["off"]
}
}],
"plugins": [
"@typescript-eslint",
"import",
"node"
],
"settings": {
"import/parsers": {
"@typescript-eslint/parser": [".ts"]
}
},
"rules": {
"indent": ["warn", 4, {
"SwitchCase": 1,
"FunctionDeclaration": {
"parameters": "first"
}
}],
"eqeqeq": ["off"],
"no-undef": "off",
"quotes": ["warn", "double", { "avoidEscape": true }],
"no-unused-vars": ["warn", {
"args": "none",
"ignoreRestSiblings": true,
"varsIgnorePattern": "^set"
}],
"no-prototype-builtins": ["off"],
"object-curly-spacing": ["warn", "never"],
"semi": ["warn", "always"],
"no-undefined": ["off"],
"array-bracket-newline": ["error", "consistent"],
"brace-style": ["error", "1tbs", {
"allowSingleLine": false
}],
"comma-spacing": ["error", {
"before": false,
"after": true
}],
"comma-style": ["error", "last"],
"comma-dangle": ["error", "never"],
"no-var": ["error"],
"import/order": ["error", {
"groups": ["builtin", "external","internal", "parent", "sibling", "index", "type", "object", "unknown"],
"warnOnUnassignedImports": true
}],
"node/file-extension-in-import": ["error", "always", {
"tryExtensions": [".js", ".json"]
}],
"newline-per-chained-call": ["error", {
"ignoreChainWithDepth": 2
}],
"no-confusing-arrow": ["error"],
"no-const-assign": ["error"],
"no-duplicate-imports": ["error", {
"includeExports": true
}],
"camelcase": ["warn"],
"jsx-quotes": ["warn"],
"yoda": ["error", "never", {
"exceptRange": true
}],
"no-eval": ["error"],
"array-callback-return": ["error"],
"valid-jsdoc": ["error", {
"requireParamType": true,
"requireReturnType": true,
"requireReturn": false,
"requireParamDescription": false,
"requireReturnDescription": false
}],
"no-empty": ["error", {
"allowEmptyCatch": true
}],
"keyword-spacing": ["warn"],
"space-infix-ops": ["warn"],
"spaced-comment": ["warn", "always"],
"eol-last": ["warn", "always"],
"max-len": ["warn", {
"code": 140,
"tabWidth": 4,
"ignoreStrings": true
}]
}
}