@@ -155,32 +155,25 @@ export default defineConfig(
155155 '@typescript-eslint/consistent-type-definitions' : 'off' ,
156156 '@typescript-eslint/prefer-for-of' : 'off' ,
157157 '@typescript-eslint/prefer-function-type' : 'off' ,
158- // disable typecheck-specific rules (but worth revisiting again)
159- '@typescript-eslint/await-thenable' : 'off' ,
160- '@typescript-eslint/dot-notation' : 'off' ,
161- '@typescript-eslint/no-base-to-string' : 'off' ,
162- '@typescript-eslint/no-duplicate-type-constituents' : 'off' ,
163- '@typescript-eslint/no-implied-eval' : 'off' ,
158+ // disable typecheck-specific rules
159+ '@typescript-eslint/await-thenable' : 'off' , // does not handle `void | Promise<void>` well
160+ '@typescript-eslint/no-base-to-string' : 'off' , // does not matter for us
161+ '@typescript-eslint/no-implied-eval' : 'off' , // we intentionally use `Function()`
164162 '@typescript-eslint/no-floating-promises' : 'off' ,
165163 '@typescript-eslint/no-misused-promises' : 'off' ,
166- '@typescript-eslint/no-redundant-type-constituents' : 'off' ,
164+ '@typescript-eslint/no-redundant-type-constituents' : 'off' , // hard to handle some cases
167165 '@typescript-eslint/no-unnecessary-type-assertion' : 'off' ,
168166 '@typescript-eslint/no-unsafe-argument' : 'off' ,
169167 '@typescript-eslint/no-unsafe-assignment' : 'off' ,
170168 '@typescript-eslint/no-unsafe-call' : 'off' ,
171- '@typescript-eslint/no-unsafe-enum-comparison' : 'off' ,
172169 '@typescript-eslint/no-unsafe-member-access' : 'off' ,
173170 '@typescript-eslint/no-unsafe-return' : 'off' ,
174- '@typescript-eslint/non-nullable-type-assertion-style' : 'off' ,
175171 '@typescript-eslint/only-throw-error' : 'off' ,
176- '@typescript-eslint/prefer-includes' : 'off' ,
177172 '@typescript-eslint/prefer-nullish-coalescing' : 'off' ,
178173 '@typescript-eslint/prefer-optional-chain' : 'off' ,
179- '@typescript-eslint/prefer-promise-reject-errors' : 'off' ,
180- '@typescript-eslint/prefer-string-starts-ends-with' : 'off' ,
174+ '@typescript-eslint/prefer-string-starts-ends-with' : 'off' , // prefer indexed access for better performance
181175 '@typescript-eslint/require-await' : 'off' ,
182- '@typescript-eslint/restrict-plus-operands' : 'off' ,
183- '@typescript-eslint/restrict-template-expressions' : 'off' ,
176+ '@typescript-eslint/restrict-template-expressions' : 'off' , // does not matter for us
184177 '@typescript-eslint/unbound-method' : 'off' ,
185178
186179 'import-x/no-duplicates' : 'error' ,
@@ -376,6 +369,14 @@ export default defineConfig(
376369 '@typescript-eslint/ban-ts-comment' : 'off' ,
377370 } ,
378371 } ,
372+ {
373+ name : 'disables/test-dts' ,
374+ files : [ '**/__tests_dts__/**/*.?([cm])[jt]s?(x)' ] ,
375+ rules : {
376+ // disable typecheck-specific rules
377+ '@typescript-eslint/no-duplicate-type-constituents' : 'off' ,
378+ } ,
379+ } ,
379380 {
380381 name : 'disables/typechecking' ,
381382 files : [
0 commit comments