Skip to content

Commit 69e2f6c

Browse files
kirkwaiblingerJoshuaKGoldberg
andauthoredApr 10, 2025··
feat: support stringly-typed extends (#10973)
* work in progress * wip * fix stuff * lintfixy stuff * why not work * yay, passing tests! * undo extraneous change * point to the new config locations * ignore dep from website build * website mocking take 2 * unused var * typo Co-authored-by: Josh Goldberg ✨ <[email protected]> * up eslint * knip ignore * alfa * Revert "up eslint" This reverts commit 7d36b57. * fix up resolution stuff * is it this * Revert "is it this" This reverts commit 97d1346. * uhhh * fixup * fixup --------- Co-authored-by: Josh Goldberg ✨ <[email protected]>
1 parent d1f57a7 commit 69e2f6c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+250
-137
lines changed
 

‎docs/users/Shared_Configurations.mdx

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ module.exports = {
144144
</TabItem>
145145
</Tabs>
146146

147-
See [`configs/recommended.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/recommended.ts) for the exact contents of this config.
147+
See [`configs/recommended.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/recommended.ts) for the exact contents of this config.
148148

149149
### `recommended-type-checked`
150150

@@ -173,7 +173,7 @@ module.exports = {
173173
</TabItem>
174174
</Tabs>
175175

176-
See [`configs/recommended-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/recommended-type-checked.ts) for the exact contents of this config.
176+
See [`configs/recommended-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/recommended-type-checked.ts) for the exact contents of this config.
177177

178178
### `strict`
179179

@@ -203,7 +203,7 @@ module.exports = {
203203
</Tabs>
204204

205205
Some rules also enabled in `recommended` default to more strict settings in this configuration.
206-
See [`configs/strict.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/strict.ts) for the exact contents of this config.
206+
See [`configs/strict.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/strict.ts) for the exact contents of this config.
207207

208208
:::tip
209209
We recommend a TypeScript project extend from `plugin:@typescript-eslint/strict` only if a nontrivial percentage of its developers are highly proficient in TypeScript.
@@ -242,7 +242,7 @@ module.exports = {
242242
</Tabs>
243243

244244
Some rules also enabled in `recommended-type-checked` default to more strict settings in this configuration.
245-
See [`configs/strict-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/strict-type-checked.ts) for the exact contents of this config.
245+
See [`configs/strict-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/strict-type-checked.ts) for the exact contents of this config.
246246

247247
:::tip
248248
We recommend a TypeScript project extend from `plugin:@typescript-eslint/strict-type-checked` only if a nontrivial percentage of its developers are highly proficient in TypeScript.
@@ -283,7 +283,7 @@ module.exports = {
283283
Note that `stylistic` does not replace `recommended` or `strict`.
284284
`stylistic` adds additional rules.
285285

286-
See [`configs/stylistic.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/stylistic.ts) for the exact contents of this config.
286+
See [`configs/stylistic.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/stylistic.ts) for the exact contents of this config.
287287

288288
### `stylistic-type-checked`
289289

@@ -315,7 +315,7 @@ module.exports = {
315315
Note that `stylistic-type-checked` does not replace `recommended-type-checked` or `strict-type-checked`.
316316
`stylistic-type-checked` adds additional rules.
317317

318-
See [`configs/stylistic-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/stylistic-type-checked.ts) for the exact contents of this config.
318+
See [`configs/stylistic-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/stylistic-type-checked.ts) for the exact contents of this config.
319319

320320
## Other Configurations
321321

@@ -326,7 +326,7 @@ typescript-eslint includes a few utility configurations.
326326
Enables each the rules provided as a part of typescript-eslint.
327327
Note that many rules are not applicable in all codebases, or are meant to be configured.
328328

329-
See [`configs/all.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/all.ts) for the exact contents of this config.
329+
See [`configs/all.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/all.ts) for the exact contents of this config.
330330

331331
:::warning
332332
We do not recommend TypeScript projects extend from `plugin:@typescript-eslint/all`.
@@ -345,14 +345,14 @@ We don't recommend using this directly; instead, extend from an earlier recommen
345345

346346
This config is automatically included if you use any of the recommended configurations.
347347

348-
See [`configs/base.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/base.ts) for the exact contents of this config.
348+
See [`configs/base.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/base.ts) for the exact contents of this config.
349349

350350
### `disable-type-checked`
351351

352352
A utility ruleset that will disable type-aware linting and all type-aware rules available in our project.
353353
This config is useful if you'd like to have your base config concerned with type-aware linting, and then conditionally use [overrides](https://eslint.org/docs/latest/use/configure/configuration-files#configuration-based-on-glob-patterns) to disable type-aware linting on specific subsets of your codebase.
354354

355-
See [`configs/disable-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/disable-type-checked.ts) for the exact contents of this config.
355+
See [`configs/disable-type-checked.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/disable-type-checked.ts) for the exact contents of this config.
356356

357357
:::info
358358
If you use type-aware rules from other plugins, you will need to manually disable these rules or use a premade config they provide to disable them.
@@ -449,7 +449,7 @@ module.exports = {
449449

450450
This config is automatically included if you use any of the recommended configurations.
451451

452-
See [`configs/eslint-recommended.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslint-recommended.ts) for the exact contents of this config.
452+
See [`configs/eslint-recommended.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/eslint-recommended.ts) for the exact contents of this config.
453453

454454
### `recommended-type-checked-only`
455455

@@ -462,7 +462,7 @@ module.exports = {
462462
};
463463
```
464464

465-
See [`configs/recommended-type-checked-only.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/recommended-type-checked-only.ts) for the exact contents of this config.
465+
See [`configs/recommended-type-checked-only.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/recommended-type-checked-only.ts) for the exact contents of this config.
466466

467467
### `strict-type-checked-only`
468468

@@ -475,7 +475,7 @@ module.exports = {
475475
};
476476
```
477477

478-
See [`configs/strict-type-checked-only.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/strict-type-checked-only.ts) for the exact contents of this config.
478+
See [`configs/strict-type-checked-only.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/strict-type-checked-only.ts) for the exact contents of this config.
479479

480480
:::warning
481481
This configuration is not considered "stable" under Semantic Versioning (semver).
@@ -493,7 +493,7 @@ module.exports = {
493493
};
494494
```
495495

496-
See [`configs/stylistic-type-checked-only.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/stylistic-type-checked-only.ts) for the exact contents of this config.
496+
See [`configs/stylistic-type-checked-only.ts`](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/src/configs/eslintrc/stylistic-type-checked-only.ts) for the exact contents of this config.
497497

498498
## Suggesting Configuration Changes
499499

‎eslint.config.mjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -646,9 +646,9 @@ export default tseslint.config(
646646
{
647647
files: ['**/*'],
648648
ignores: [
649-
'packages/eslint-plugin/src/configs/*',
649+
'packages/eslint-plugin/src/configs/eslintrc/*',
650+
'packages/eslint-plugin/src/configs/flat/*',
650651
'packages/scope-manager/src/configs/*',
651-
'packages/typescript-eslint/src/configs/*',
652652
],
653653
rules: {
654654
'@typescript-eslint/sort-type-constituents': 'off',

0 commit comments

Comments
 (0)
Please sign in to comment.