|
1 | 1 | module.exports = { |
2 | | - extends: ['plugin:prettier/recommended'], |
3 | | - plugins: ['prettier', '@typescript-eslint'], |
4 | | - parser: '@typescript-eslint/parser', |
5 | | - parserOptions: { |
6 | | - ecmaVersion: 2018, |
7 | | - sourceType: 'module', |
8 | | - parser: '@typescript-eslint/parser', |
9 | | - project: 'tsconfig.eslint.json', |
10 | | - warnOnUnsupportedTypeScriptVersion: false, |
11 | | - tsconfigRootDir: __dirname, |
12 | | - }, |
13 | | - rules: { |
14 | | - 'prettier/prettier': 'warn', |
15 | | - '@typescript-eslint/adjacent-overload-signatures': 'error', |
16 | | - '@typescript-eslint/array-type': 'error', |
17 | | - '@typescript-eslint/await-thenable': 'error', |
18 | | - '@typescript-eslint/ban-types': 'off', |
19 | | - '@typescript-eslint/class-name-casing': 'off', |
20 | | - '@typescript-eslint/consistent-type-assertions': 'error', |
21 | | - '@typescript-eslint/consistent-type-definitions': 'error', |
22 | | - '@typescript-eslint/explicit-member-accessibility': [ |
23 | | - 'off', |
24 | | - { |
25 | | - accessibility: 'explicit', |
26 | | - }, |
27 | | - ], |
28 | | - '@typescript-eslint/indent': [ |
29 | | - 'error', |
30 | | - 4, |
31 | | - { |
32 | | - FunctionDeclaration: { |
33 | | - parameters: 'first', |
34 | | - }, |
35 | | - FunctionExpression: { |
36 | | - parameters: 'first', |
37 | | - }, |
38 | | - SwitchCase: 1, |
39 | | - }, |
40 | | - ], |
41 | | - '@typescript-eslint/interface-name-prefix': 'off', |
42 | | - '@typescript-eslint/member-delimiter-style': 'error', |
43 | | - '@typescript-eslint/member-ordering': 'off', |
44 | | - '@typescript-eslint/no-empty-function': 'off', |
45 | | - '@typescript-eslint/no-empty-interface': 'off', |
46 | | - '@typescript-eslint/no-explicit-any': 'off', |
47 | | - '@typescript-eslint/no-floating-promises': 'off', |
48 | | - '@typescript-eslint/no-inferrable-types': 'off', |
49 | | - '@typescript-eslint/no-misused-new': 'off', |
50 | | - '@typescript-eslint/no-namespace': 'off', |
51 | | - '@typescript-eslint/no-parameter-properties': 'off', |
52 | | - '@typescript-eslint/no-require-imports': 'off', |
53 | | - '@typescript-eslint/no-unnecessary-qualifier': 'error', |
54 | | - '@typescript-eslint/no-unnecessary-type-assertion': 'error', |
55 | | - '@typescript-eslint/no-use-before-declare': 'off', |
56 | | - '@typescript-eslint/no-var-requires': 'off', |
57 | | - '@typescript-eslint/prefer-for-of': 'off', |
58 | | - '@typescript-eslint/prefer-function-type': 'error', |
59 | | - '@typescript-eslint/prefer-namespace-keyword': 'error', |
60 | | - '@typescript-eslint/quotes': [ |
61 | | - 'error', |
62 | | - 'single', |
63 | | - { |
64 | | - avoidEscape: true, |
65 | | - }, |
66 | | - ], |
67 | | - '@typescript-eslint/semi': ['error'], |
68 | | - '@typescript-eslint/space-within-parens': ['off', 'never'], |
69 | | - '@typescript-eslint/triple-slash-reference': 'off', |
70 | | - '@typescript-eslint/type-annotation-spacing': 'error', |
71 | | - '@typescript-eslint/unified-signatures': 'error', |
72 | | - 'arrow-body-style': 'error', |
73 | | - 'arrow-parens': ['off', 'as-needed'], |
74 | | - camelcase: 'off', |
75 | | - 'capitalized-comments': 'off', |
76 | | - complexity: 'off', |
77 | | - 'constructor-super': 'error', |
78 | | - curly: ['error', 'multi-line'], |
79 | | - 'dot-notation': 'off', |
80 | | - 'eol-last': 'error', |
81 | | - eqeqeq: ['error', 'smart'], |
82 | | - 'guard-for-in': 'off', |
83 | | - 'id-blacklist': ['error', 'any', 'string', 'boolean', 'Undefined'], |
84 | | - 'id-match': 'error', |
85 | | - 'sort-imports': [ |
86 | | - 'error', |
87 | | - { |
88 | | - ignoreCase: false, |
89 | | - ignoreDeclarationSort: true, |
90 | | - ignoreMemberSort: false, |
91 | | - memberSyntaxSortOrder: ['none', 'all', 'multiple', 'single'], |
92 | | - }, |
93 | | - ], |
94 | | - 'linebreak-style': 'off', |
95 | | - 'max-classes-per-file': 'off', |
96 | | - 'max-len': [ |
97 | | - 'off', |
98 | | - { |
99 | | - ignorePattern: '^import |^export {(.*?)}', |
100 | | - code: 200, |
101 | | - }, |
102 | | - ], |
103 | | - 'new-parens': 'off', |
104 | | - 'newline-per-chained-call': 'off', |
105 | | - 'no-bitwise': 'off', |
106 | | - 'no-caller': 'error', |
107 | | - 'no-cond-assign': 'off', |
108 | | - 'no-console': [ |
109 | | - 'off', |
110 | | - { |
111 | | - allow: [ |
112 | | - 'log', |
113 | | - 'warn', |
114 | | - 'dir', |
115 | | - 'timeLog', |
116 | | - 'assert', |
117 | | - 'clear', |
118 | | - 'count', |
119 | | - 'countReset', |
120 | | - 'group', |
121 | | - 'groupEnd', |
122 | | - 'table', |
123 | | - 'debug', |
124 | | - 'dirxml', |
125 | | - 'error', |
126 | | - 'groupCollapsed', |
127 | | - 'Console', |
128 | | - 'profile', |
129 | | - 'profileEnd', |
130 | | - 'timeStamp', |
131 | | - 'context', |
132 | | - ], |
133 | | - }, |
134 | | - ], |
135 | | - 'no-constant-condition': 'error', |
136 | | - 'no-control-regex': 'off', |
137 | | - 'no-debugger': 'error', |
138 | | - 'no-duplicate-imports': 'error', |
139 | | - 'no-empty': 'off', |
140 | | - 'no-eval': 'off', |
141 | | - 'no-extra-semi': 'off', |
142 | | - 'no-fallthrough': 'error', |
143 | | - 'no-invalid-regexp': 'error', |
144 | | - 'no-invalid-this': 'off', |
145 | | - 'no-irregular-whitespace': 'off', |
146 | | - 'no-multiple-empty-lines': 'off', |
147 | | - 'no-new-wrappers': 'error', |
148 | | - 'no-redeclare': ['error', { builtinGlobals: false }], |
149 | | - 'no-regex-spaces': 'error', |
150 | | - 'no-return-await': 'error', |
151 | | - 'no-shadow': [ |
152 | | - 'off', |
153 | | - { |
154 | | - hoist: 'all', |
155 | | - }, |
156 | | - ], |
157 | | - 'no-throw-literal': 'error', |
158 | | - 'no-trailing-spaces': 'error', |
159 | | - 'no-undef-init': 'error', |
160 | | - 'no-underscore-dangle': 'off', |
161 | | - 'no-unsafe-finally': 'error', |
162 | | - 'no-unused-expressions': [ |
163 | | - 'error', |
164 | | - { |
165 | | - allowTaggedTemplates: true, |
166 | | - allowShortCircuit: true, |
167 | | - }, |
168 | | - ], |
169 | | - 'no-unused-labels': 'error', |
170 | | - 'no-var': 'error', |
171 | | - 'object-shorthand': 'error', |
172 | | - 'one-var': ['off', 'never'], |
173 | | - 'prefer-arrow/prefer-arrow-functions': 'off', |
174 | | - 'prefer-const': 'error', |
175 | | - 'quote-props': 'off', |
176 | | - radix: 'error', |
177 | | - 'space-before-function-paren': 'off', |
178 | | - 'use-isnan': 'error', |
179 | | - 'valid-typeof': 'off', |
180 | | - }, |
| 2 | + extends: './tools/.eslintrc.js' |
181 | 3 | }; |
0 commit comments