Open History to see the last commit
1// @ts-check
2// @ts-ignore: no types for eslint-config-preact
3import preact from 'eslint-config-preact'
4// eslint-config-preact uses typescript-eslint under the hood
5import tseslint from 'typescript-eslint'
6β
7import rootConfig from './root.eslint.config.js'
8β
9export default [
10 ...rootConfig,
11 ...preact,
12 {
13 files: ['**/*.{ts,tsx}'],
14 languageOptions: {
15 parser: tseslint.parser,
16 parserOptions: {
17 project: true,
18 },
19 },
20 plugins: {
21 'typescript-eslint': tseslint.plugin,
22 },
23 rules: {
24 // Disable base rule to prevent overload false positives
25 'no-redeclare': 'off',
26 'no-duplicate-imports': 'off',
27 'no-unused-vars': 'off',
28 'import/order': 'off',
29 'sort-imports': 'off',
30 'no-import-assign': 'off',
31 // TS-aware version handles overloads correctly
32 '@typescript-eslint/no-redeclare': 'error',
33 '@typescript-eslint/array-type': 'off',
34 '@typescript-eslint/no-unnecessary-type-assertion': 'off',
35 '@typescript-eslint/no-unnecessary-condition': 'off',
36 },
37 },
38]