feat(eslint-config-fluid): Enable new TypeScript rules as warnings#25508
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adds three new TypeScript ESLint rules as warnings to prepare for a future major version update where deprecated rules will be removed. The new rules replace deprecated ones that are being phased out by the TypeScript ESLint plugin.
- Adds
no-empty-object-type,no-unsafe-function-type, andno-wrapper-object-typesrules as warnings - Updates all ESLint configuration variants to include the new rules
- Positions the new rules in a temporary section for promotion to errors in version 7.0.0
Reviewed Changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| base.js | Adds the three new TypeScript ESLint rules as warnings in a temporary section |
| default.json | Updates the default configuration with the new warning rules |
| minimal.json | Updates the minimal configuration with the new warning rules |
| react.json | Updates the React configuration with the new warning rules |
| recommended.json | Updates the recommended configuration with the new warning rules |
| strict.json | Updates the strict configuration with the new warning rules |
| strict-biome.json | Updates the strict-biome configuration with the new warning rules |
| test.json | Updates the test configuration with the new warning rules |
|
I'm confused. The new rules weren't showing up at all in the printed configs before this change... so they were not being applied as errors yet? Is this making them warnings before we do the dep updates that bring those new rules in? (I know there's been several PRs around this, I couldn't keep track of their statuses). |
The rules are defined as of the current dep version we have on typescript-eslint. But they are not added to the "recommended" config we extend. They are added to the recommended config in the next major version of the dep. To aid in making the new rules a bit more discoverable, I've promoted them to warnings. They will be promoted to errors in the next major version of this library (and the deprecated rules from the typescript-eslint library will be removed). |
|
🔗 No broken links found! ✅ Your attention to detail is admirable. linkcheck output |
…icrosoft#25508) `@typescript-eslint/eslint-plugin` has deprecated and disabled the following rules: - [ban-types](https://typescript-eslint.io/rules/ban-types/) - [no-empty-interface](https://typescript-eslint.io/rules/no-empty-interface/) They are replaced by the following new rules, which are now configured as errors in this library: - [no-empty-object-type](https://typescript-eslint.io/rules/no-empty-object-type/) - [no-unsafe-function-type](https://typescript-eslint.io/rules/no-unsafe-function-type/) - [no-wrapper-object-types](https://typescript-eslint.io/rules/no-wrapper-object-types/) This PR pre-emptively updates our configs to set these new rules as warnings. In the next major version bump, the old rules will be removed and these new rules will be promoted to errors.
@typescript-eslint/eslint-pluginhas deprecated and disabled the following rules:They are replaced by the following new rules, which are now configured as errors in this library:
This PR pre-emptively updates our configs to set these new rules as warnings. In the next major version bump, the old rules will be removed and these new rules will be promoted to errors.