@d-zero/eslint-config 5.0.0-alpha.52 → 5.0.0-alpha.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -8,34 +8,48 @@ npm install -D @d-zero/eslint-config
8
8
 
9
9
  ## 使い方
10
10
 
11
- `.eslintrc`を作成し、[`extends`](https://eslint.org/docs/latest/use/configure/configuration-files#extending-configuration-files)機能を使って読み込みます。
11
+ `eslint.config.js`を作成し、`import`からコンフィグデータを読み込みます。
12
12
 
13
- ```json
14
- {
15
- "extends": ["@d-zero/eslint-config"]
16
- }
13
+ ```js
14
+ import dz from '@d-zero/eslint-config';
15
+
16
+ /**
17
+ * @type {import('eslint').ESLint.ConfigData[]}
18
+ */
19
+ export default [...dz.configs.frontend];
17
20
  ```
18
21
 
19
22
  ### 拡張
20
23
 
21
24
  プロジェクトに合わせて設定を追加します。
22
25
 
23
- ```json
24
- {
25
- "extends": ["@d-zero/eslint-config"],
26
- "rules": {
27
- // 例: console.logを許可する
28
- "no-console": 0
29
- }
30
- }
26
+ ```js
27
+ import dz from '@d-zero/eslint-config';
28
+
29
+ /**
30
+ * @type {import('eslint').ESLint.ConfigData[]}
31
+ */
32
+ export default [
33
+ ...dz.configs.frontend,
34
+ {
35
+ rules: {
36
+ // 例: console.logを許可する
37
+ 'no-console': 0,
38
+ },
39
+ },
40
+ ];
31
41
  ```
32
42
 
33
- ## JavaScriptのみ
43
+ ### プリセット
34
44
 
35
- :warning: TypeScriptを利用**しない**場合は、`@d-zero/eslint-config`の代わりに`@d-zero/eslint-config/base`を利用します。
45
+ 以下のプリセットが用意されています。
36
46
 
37
- ```json
38
- {
39
- "extends": ["@d-zero/eslint-config/base"]
40
- }
41
- ```
47
+ | プロパティ | 型 | 説明 |
48
+ | ---------------------- | -------- | -------------------------------------------------- |
49
+ | `configs.frontend` | `Array` | フロントエンド開発用 |
50
+ | `configs.frontendNoTS` | `Array` | フロントエンド開発用(TypeScriptを利用しない場合) |
51
+ | `configs.node` | `Array` | Node.js開発用 |
52
+ | `configs.nodeNoTS` | `Array` | Node.js開発用(TypeScriptを利用しない場合) |
53
+ | `configs.standard` | `Array` | `config.node`と同じ |
54
+ | `configs.base` | `Array` | `config.nodeNoTS`と同じ |
55
+ | `configs.commonjs` | `Object` | CommonJS用単一設定 |
package/base.js CHANGED
@@ -1,228 +1,252 @@
1
+ import js from '@eslint/js';
2
+ import comments from 'eslint-plugin-eslint-comments';
3
+ import importPlugin from 'eslint-plugin-import';
4
+ import jsdoc from 'eslint-plugin-jsdoc';
5
+ import * as regexpPlugin from 'eslint-plugin-regexp';
6
+ import sortClassMembers from 'eslint-plugin-sort-class-members';
7
+ import eslintPluginUnicorn from 'eslint-plugin-unicorn';
8
+ import globals from 'globals';
9
+
1
10
  /**
2
- * @type {import('eslint/lib/shared/types').ConfigData}
11
+ * @type {import('eslint').Linter.Config[]}
3
12
  */
4
- module.exports = {
5
- extends: [
6
- 'eslint:recommended',
7
- 'plugin:unicorn/recommended',
8
- 'plugin:regexp/recommended',
9
- 'plugin:import/recommended',
10
- ],
11
- env: {
12
- browser: true,
13
- es6: true,
14
- node: true,
15
- },
16
- plugins: ['unicorn', 'jsdoc', 'eslint-comments', 'import', 'sort-class-members'],
17
- parserOptions: {
18
- ecmaVersion: 2023,
13
+ export const base = [
14
+ {
15
+ ...js.configs.recommended,
16
+ rules: {
17
+ ...js.configs.recommended.rules,
18
+ 'no-console': 'warn',
19
+ 'no-mixed-spaces-and-tabs': 0,
20
+ 'no-restricted-syntax': [
21
+ 2,
22
+ {
23
+ selector:
24
+ ':matches(PropertyDefinition, MethodDefinition)[accessibility="private"]',
25
+ message: 'Use #private instead',
26
+ },
27
+ {
28
+ selector:
29
+ ':matches(PropertyDefinition, MethodDefinition)[accessibility="public"]',
30
+ message: 'Remove public keyword',
31
+ },
32
+ {
33
+ selector: 'MethodDefinition[key.name=/^_/]:not([accessibility="protected"])',
34
+ message: 'Add protected keyword',
35
+ },
36
+ {
37
+ selector: 'MethodDefinition:not([key.name=/^_/])[accessibility="protected"]',
38
+ message: 'Start with `_` if you want to use protected',
39
+ },
40
+ {
41
+ selector:
42
+ "CallExpression[callee.property.name='addEventListener'][arguments.0.value='DOMContentLoaded']",
43
+ message:
44
+ "Avoid using 'DOMContentLoaded'. Use 'defer' or 'type=module' attribute instead.",
45
+ },
46
+ ],
47
+ 'no-unused-vars': 0,
48
+ 'no-var': 2,
49
+ 'prefer-const': 2,
50
+ 'prefer-rest-params': 2,
51
+ 'prefer-spread': 2,
52
+ },
19
53
  },
20
- globals: {
21
- NodeJS: true,
54
+ {
55
+ ...eslintPluginUnicorn.configs['flat/recommended'],
56
+ rules: {
57
+ ...eslintPluginUnicorn.configs['flat/recommended'].rules,
58
+ 'unicorn/consistent-destructuring': 0,
59
+ 'unicorn/consistent-function-scoping': 0,
60
+ 'unicorn/no-anonymous-default-export': 0,
61
+ 'unicorn/no-array-callback-reference': 0,
62
+ 'unicorn/no-nested-ternary': 0,
63
+ 'unicorn/no-null': 0,
64
+ 'unicorn/no-process-exit': 0,
65
+ 'unicorn/prefer-global-this': 0,
66
+ 'unicorn/prefer-query-selector': 0,
67
+ 'unicorn/prefer-string-raw': 0,
68
+ 'unicorn/prefer-ternary': 0,
69
+ 'unicorn/prevent-abbreviations': 0,
70
+ },
22
71
  },
23
- rules: {
24
- // Standard
25
- 'no-console': 'warn',
26
- 'no-mixed-spaces-and-tabs': 0,
27
- 'no-restricted-syntax': [
28
- 2,
29
- {
30
- selector:
31
- ':matches(PropertyDefinition, MethodDefinition)[accessibility="private"]',
32
- message: 'Use #private instead',
33
- },
34
- {
35
- selector:
36
- ':matches(PropertyDefinition, MethodDefinition)[accessibility="public"]',
37
- message: 'Remove public keyword',
38
- },
39
- {
40
- selector: 'MethodDefinition[key.name=/^_/]:not([accessibility="protected"])',
41
- message: 'Add protected keyword',
42
- },
43
- {
44
- selector: 'MethodDefinition:not([key.name=/^_/])[accessibility="protected"]',
45
- message: 'Start with `_` if you want to use protected',
46
- },
47
- {
48
- selector:
49
- "CallExpression[callee.property.name='addEventListener'][arguments.0.value='DOMContentLoaded']",
50
- message:
51
- "Avoid using 'DOMContentLoaded'. Use 'defer' or 'type=module' attribute instead.",
52
- },
53
- ],
54
- 'no-unused-vars': 0,
55
- 'no-var': 2,
56
- 'prefer-const': 2,
57
- 'prefer-rest-params': 2,
58
- 'prefer-spread': 2,
59
-
60
- // Unicorn
61
- 'unicorn/consistent-destructuring': 0,
62
- 'unicorn/consistent-function-scoping': 0,
63
- 'unicorn/no-anonymous-default-export': 0,
64
- 'unicorn/no-array-callback-reference': 0,
65
- 'unicorn/no-nested-ternary': 0,
66
- 'unicorn/no-null': 0,
67
- 'unicorn/no-process-exit': 0,
68
- 'unicorn/prefer-global-this': 0,
69
- 'unicorn/prefer-query-selector': 0,
70
- 'unicorn/prefer-string-raw': 0,
71
- 'unicorn/prefer-ternary': 0,
72
- 'unicorn/prevent-abbreviations': 0,
73
-
74
- // import
75
- 'import/no-extraneous-dependencies': 2,
76
- 'import/no-named-as-default': 0,
77
- 'import/no-unresolved': 0,
78
- 'import/order': [
79
- 2,
80
- {
81
- groups: ['type', 'builtin', 'external', 'parent', 'sibling', 'index', 'object'],
82
- pathGroups: [
83
- {
84
- pattern: '@alias/**',
85
- group: 'parent',
86
- position: 'before',
87
- },
88
- ],
89
- alphabetize: {
90
- order: 'asc',
91
- },
92
- 'newlines-between': 'always',
93
- },
94
- ],
95
-
96
- // Sort Class members
97
- 'sort-class-members/sort-class-members': [
98
- 1,
99
- {
100
- order: [
101
- '[public-properties]',
102
- '[public-readonly-properties]',
103
- '[public-properties-function]',
104
- '[private-properties]',
105
- '[private-properties-function]',
106
- '[accessor-pairs]',
107
- '[getters]',
108
- '[setters]',
109
- 'constructor',
110
- '[public-methods]',
111
- '[private-methods]',
112
- '[protedted-methods]',
113
- '[static-properties]',
114
- '[static-methods]',
115
- '[everything-else]',
116
- ],
117
- groups: {
118
- 'public-properties': [
119
- {
120
- type: 'property',
121
- kind: 'nonAccessor',
122
- static: false,
123
- private: false,
124
- override: false,
125
- readonly: false,
126
- sort: 'alphabetical',
127
- },
128
- ],
129
- 'public-readonly-properties': [
130
- {
131
- type: 'property',
132
- kind: 'nonAccessor',
133
- static: false,
134
- private: false,
135
- override: false,
136
- readonly: true,
137
- sort: 'alphabetical',
138
- },
139
- ],
140
- 'public-properties-function': [
141
- {
142
- type: 'property',
143
- propertyType: 'ArrowFunctionExpression',
144
- kind: 'nonAccessor',
145
- static: false,
146
- private: false,
147
- accessibility: 'public',
148
- override: false,
149
- sort: 'alphabetical',
150
- },
151
- ],
152
- 'private-properties': [
153
- {
154
- type: 'property',
155
- kind: 'nonAccessor',
156
- static: false,
157
- private: true,
158
- override: false,
159
- sort: 'alphabetical',
160
- },
161
- ],
162
- 'private-properties-function': [
163
- {
164
- type: 'property',
165
- propertyType: 'ArrowFunctionExpression',
166
- kind: 'nonAccessor',
167
- static: false,
168
- private: true,
169
- accessibility: 'public',
170
- override: false,
171
- sort: 'alphabetical',
172
- },
173
- ],
174
- 'public-methods': [
72
+ regexpPlugin.configs['flat/recommended'],
73
+ {
74
+ ...importPlugin.flatConfigs.recommended,
75
+ rules: {
76
+ ...importPlugin.flatConfigs.recommended.rules,
77
+ 'import/no-extraneous-dependencies': 2,
78
+ 'import/no-named-as-default': 0,
79
+ 'import/no-unresolved': 0,
80
+ 'import/order': [
81
+ 2,
82
+ {
83
+ groups: ['type', 'builtin', 'external', 'parent', 'sibling', 'index', 'object'],
84
+ pathGroups: [
175
85
  {
176
- type: 'method',
177
- kind: 'nonAccessor',
178
- static: false,
179
- private: false,
180
- override: false,
181
- sort: 'alphabetical',
182
- },
183
- ],
184
- 'private-methods': [
185
- {
186
- name: '/#.+/',
187
- type: 'method',
188
- kind: 'nonAccessor',
189
- static: false,
190
- private: true,
191
- override: false,
192
- sort: 'alphabetical',
193
- },
194
- ],
195
- 'protedted-methods': [
196
- {
197
- name: '/_.+/',
198
- type: 'method',
199
- static: false,
200
- sort: 'alphabetical',
86
+ pattern: '@alias/**',
87
+ group: 'parent',
88
+ position: 'before',
201
89
  },
202
90
  ],
91
+ alphabetize: {
92
+ order: 'asc',
93
+ },
94
+ 'newlines-between': 'always',
203
95
  },
204
- accessorPairPositioning: 'getThenSet',
205
- },
96
+ ],
97
+ },
98
+ },
99
+ {
100
+ files: [
101
+ '*.{test,spec}.{js,mjs,json}',
102
+ '*.config.{js,mjs,json}',
103
+ '.*rc.{js,mjs,json}',
206
104
  ],
105
+ rules: {
106
+ 'import/no-extraneous-dependencies': 0,
107
+ },
207
108
  },
208
- settings: {
209
- jsdoc: {
210
- tagNamePreference: {
211
- param: 'arg',
212
- returns: 'return',
213
- },
109
+ {
110
+ ...jsdoc.configs['flat/recommended'],
111
+ rules: {
112
+ ...jsdoc.configs['flat/recommended'].rules,
113
+ 'jsdoc/require-param-type': 0,
114
+ 'jsdoc/require-param-description': 0,
115
+ 'jsdoc/require-returns': 0,
116
+ 'jsdoc/require-returns-type': 0,
117
+ 'jsdoc/require-returns-description': 0,
118
+ },
119
+ },
120
+ {
121
+ plugins: {
122
+ comments,
214
123
  },
215
124
  },
216
- overrides: [
217
- {
218
- files: [
219
- '*.{test,spec}.{js,mjs,json}',
220
- '*.config.{js,mjs,json}',
221
- '.*rc.{js,mjs,json}',
125
+ {
126
+ plugins: {
127
+ comments,
128
+ 'sort-class-members': sortClassMembers,
129
+ },
130
+ rules: {
131
+ 'sort-class-members/sort-class-members': [
132
+ 1,
133
+ {
134
+ order: [
135
+ '[public-properties]',
136
+ '[public-readonly-properties]',
137
+ '[public-properties-function]',
138
+ '[private-properties]',
139
+ '[private-properties-function]',
140
+ '[accessor-pairs]',
141
+ '[getters]',
142
+ '[setters]',
143
+ 'constructor',
144
+ '[public-methods]',
145
+ '[private-methods]',
146
+ '[protedted-methods]',
147
+ '[static-properties]',
148
+ '[static-methods]',
149
+ '[everything-else]',
150
+ ],
151
+ groups: {
152
+ 'public-properties': [
153
+ {
154
+ type: 'property',
155
+ kind: 'nonAccessor',
156
+ static: false,
157
+ private: false,
158
+ override: false,
159
+ readonly: false,
160
+ sort: 'alphabetical',
161
+ },
162
+ ],
163
+ 'public-readonly-properties': [
164
+ {
165
+ type: 'property',
166
+ kind: 'nonAccessor',
167
+ static: false,
168
+ private: false,
169
+ override: false,
170
+ readonly: true,
171
+ sort: 'alphabetical',
172
+ },
173
+ ],
174
+ 'public-properties-function': [
175
+ {
176
+ type: 'property',
177
+ propertyType: 'ArrowFunctionExpression',
178
+ kind: 'nonAccessor',
179
+ static: false,
180
+ private: false,
181
+ accessibility: 'public',
182
+ override: false,
183
+ sort: 'alphabetical',
184
+ },
185
+ ],
186
+ 'private-properties': [
187
+ {
188
+ type: 'property',
189
+ kind: 'nonAccessor',
190
+ static: false,
191
+ private: true,
192
+ override: false,
193
+ sort: 'alphabetical',
194
+ },
195
+ ],
196
+ 'private-properties-function': [
197
+ {
198
+ type: 'property',
199
+ propertyType: 'ArrowFunctionExpression',
200
+ kind: 'nonAccessor',
201
+ static: false,
202
+ private: true,
203
+ accessibility: 'public',
204
+ override: false,
205
+ sort: 'alphabetical',
206
+ },
207
+ ],
208
+ 'public-methods': [
209
+ {
210
+ type: 'method',
211
+ kind: 'nonAccessor',
212
+ static: false,
213
+ private: false,
214
+ override: false,
215
+ sort: 'alphabetical',
216
+ },
217
+ ],
218
+ 'private-methods': [
219
+ {
220
+ name: '/#.+/',
221
+ type: 'method',
222
+ kind: 'nonAccessor',
223
+ static: false,
224
+ private: true,
225
+ override: false,
226
+ sort: 'alphabetical',
227
+ },
228
+ ],
229
+ 'protedted-methods': [
230
+ {
231
+ name: '/_.+/',
232
+ type: 'method',
233
+ static: false,
234
+ sort: 'alphabetical',
235
+ },
236
+ ],
237
+ },
238
+ accessorPairPositioning: 'getThenSet',
239
+ },
222
240
  ],
223
- rules: {
224
- 'import/no-extraneous-dependencies': 0,
241
+ },
242
+ },
243
+ {
244
+ languageOptions: {
245
+ ecmaVersion: 2023,
246
+ globals: {
247
+ ...globals.builtin,
248
+ ...globals.nodeBuiltin,
225
249
  },
226
250
  },
227
- ],
228
- };
251
+ },
252
+ ];
package/commonjs.js ADDED
@@ -0,0 +1,16 @@
1
+ import globals from 'globals';
2
+
3
+ /**
4
+ * @type {import('eslint').Linter.Config}
5
+ */
6
+ export const commonjs = {
7
+ rules: {
8
+ 'unicorn/prefer-module': 0,
9
+ '@typescript-eslint/no-require-imports': 0,
10
+ },
11
+ languageOptions: {
12
+ globals: {
13
+ ...globals.commonjs,
14
+ },
15
+ },
16
+ };
package/frontend.js CHANGED
@@ -1,12 +1,15 @@
1
- const ts = require('./typescript');
1
+ import globals from 'globals';
2
2
 
3
3
  /**
4
- * @type {import('eslint/lib/shared/types').ConfigData}
4
+ * @type {import('eslint').Linter.Config}
5
5
  */
6
- module.exports = {
7
- ...ts,
6
+ export const frontend = {
8
7
  rules: {
9
- ...ts.rules,
10
8
  'unicorn/prefer-top-level-await': 0,
11
9
  },
10
+ languageOptions: {
11
+ globals: {
12
+ ...globals.browser,
13
+ },
14
+ },
12
15
  };
package/index.js ADDED
@@ -0,0 +1,19 @@
1
+ import { base } from './base.js';
2
+ import { commonjs } from './commonjs.js';
3
+ import { frontend } from './frontend.js';
4
+ import { ts } from './typescript.js';
5
+
6
+ /**
7
+ * @type {import('eslint').ESLint.Plugin}
8
+ */
9
+ export default {
10
+ configs: {
11
+ standard: [...ts],
12
+ base: [...base],
13
+ node: [...ts],
14
+ nodeNoTS: [...base],
15
+ frontend: [...ts, frontend],
16
+ frontendNoTS: [...base, frontend],
17
+ commonjs,
18
+ },
19
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@d-zero/eslint-config",
3
- "version": "5.0.0-alpha.52",
3
+ "version": "5.0.0-alpha.54",
4
4
  "description": "Configurations of ESLint",
5
5
  "repository": "https://github.com/d-zero-dev/linters.git",
6
6
  "author": "D-ZERO Co., Ltd.",
@@ -13,33 +13,23 @@
13
13
  "node": ">=22.0.0"
14
14
  },
15
15
  "files": [
16
- "base.js",
17
- "frontend.js",
18
- "typescript.js"
16
+ "*.js"
19
17
  ],
20
- "type": "commonjs",
21
- "main": "frontend.js",
18
+ "type": "module",
22
19
  "exports": {
23
- ".": {
24
- "require": "./frontend.js"
25
- },
26
- "./base": {
27
- "require": "./base.js"
28
- },
29
- "./node": {
30
- "require": "./node.js"
31
- }
20
+ ".": "./index.js"
32
21
  },
33
22
  "dependencies": {
34
- "@typescript-eslint/eslint-plugin": "8.17.0",
35
- "@typescript-eslint/parser": "8.17.0",
36
- "eslint": "8.57.1",
23
+ "@eslint/js": "9.17.0",
24
+ "eslint": "9.17.0",
37
25
  "eslint-plugin-eslint-comments": "3.2.0",
38
26
  "eslint-plugin-import": "2.31.0",
39
- "eslint-plugin-jsdoc": "50.6.0",
27
+ "eslint-plugin-jsdoc": "50.6.1",
40
28
  "eslint-plugin-regexp": "2.7.0",
41
29
  "eslint-plugin-sort-class-members": "1.21.0",
42
- "eslint-plugin-unicorn": "56.0.1"
30
+ "eslint-plugin-unicorn": "56.0.1",
31
+ "globals": "15.13.0",
32
+ "typescript-eslint": "8.18.0"
43
33
  },
44
- "gitHead": "68e226da6791383d100854506fc048a757436283"
34
+ "gitHead": "d8db0b37986eafd021c1210a7ed47567be133bfd"
45
35
  }
package/typescript.js CHANGED
@@ -1,51 +1,44 @@
1
- const base = require('./base');
1
+ import tsESLint from 'typescript-eslint';
2
2
 
3
- /**
4
- * @type {import('eslint/lib/shared/types').ConfigData}
5
- */
6
- module.exports = {
7
- ...base,
8
- overrides: [
9
- ...base.overrides,
10
- {
11
- files: ['*.{ts,tsx}', '**/*.{ts,tsx}'],
12
- extends: ['plugin:import/typescript', 'plugin:@typescript-eslint/recommended'],
13
- plugins: ['@typescript-eslint', ...base.plugins],
14
- parser: '@typescript-eslint/parser',
3
+ import { base } from './base.js';
4
+
5
+ export const ts = tsESLint.config(
6
+ base,
7
+ tsESLint.configs.recommended,
8
+ {
9
+ files: ['*.{ts,tsx}', '**/*.{ts,tsx}'],
10
+ languageOptions: {
15
11
  parserOptions: {
16
12
  sourceType: 'module',
17
13
  project: ['./tsconfig.json'],
18
14
  },
19
- settings: {
20
- ...base.settings,
21
- 'import/parsers': {
22
- '@typescript-eslint/parser': ['.ts'],
23
- },
24
- },
25
- rules: {
26
- ...base.rules,
27
- // @typescript-eslint
28
- '@typescript-eslint/adjacent-overload-signatures': 2,
29
- '@typescript-eslint/ban-ts-comment': 0,
30
- '@typescript-eslint/consistent-type-imports': 1,
31
- '@typescript-eslint/member-ordering': 0,
32
- '@typescript-eslint/no-array-constructor': 2,
33
- '@typescript-eslint/no-explicit-any': [1, { fixToUnknown: true }],
34
- '@typescript-eslint/no-floating-promises': 2,
35
- '@typescript-eslint/no-namespace': [2, { allowDeclarations: true }],
36
- '@typescript-eslint/no-unnecessary-type-assertion': 2,
37
- '@typescript-eslint/no-unused-vars': 2,
38
- '@typescript-eslint/no-var-requires': 2,
39
- '@typescript-eslint/prefer-namespace-keyword': 2,
40
- '@typescript-eslint/require-await': 2,
41
- '@typescript-eslint/restrict-plus-operands': 0,
42
- },
43
15
  },
44
- {
45
- files: ['*.{test,spec}.{ts,mts,tsx}'],
46
- rules: {
47
- 'import/no-extraneous-dependencies': 0,
16
+ settings: {
17
+ 'import/parsers': {
18
+ '@typescript-eslint/parser': ['.ts'],
48
19
  },
49
20
  },
50
- ],
51
- };
21
+ rules: {
22
+ '@typescript-eslint/adjacent-overload-signatures': 2,
23
+ '@typescript-eslint/ban-ts-comment': 0,
24
+ '@typescript-eslint/consistent-type-imports': 1,
25
+ '@typescript-eslint/member-ordering': 0,
26
+ '@typescript-eslint/no-array-constructor': 2,
27
+ '@typescript-eslint/no-explicit-any': [1, { fixToUnknown: true }],
28
+ '@typescript-eslint/no-floating-promises': 2,
29
+ '@typescript-eslint/no-namespace': [2, { allowDeclarations: true }],
30
+ '@typescript-eslint/no-unnecessary-type-assertion': 2,
31
+ '@typescript-eslint/no-unused-vars': 2,
32
+ '@typescript-eslint/no-var-requires': 2,
33
+ '@typescript-eslint/prefer-namespace-keyword': 2,
34
+ '@typescript-eslint/require-await': 2,
35
+ '@typescript-eslint/restrict-plus-operands': 0,
36
+ },
37
+ },
38
+ {
39
+ files: ['*.{test,spec}.{ts,mts,tsx}'],
40
+ rules: {
41
+ 'import/no-extraneous-dependencies': 0,
42
+ },
43
+ },
44
+ );