Commit 8dfd19e
committed
[code-infra] Migrate to ESLint 10
This PR prepares the codebase for ESLint 10 migration.
- Update `eslint` from 9.39.2 to ^10.0.3
- Update `@mui/internal-code-infra` to use temp published package from
PR
- Add `@eslint/compat` dependency for plugin compatibility
- Wrap `eslint-plugin-consistent-default-export-name` with
`fixupPluginRules` for ESLint 10 compatibility
- Add `packageExtensions` to override peer dependencies for ESLint
plugins not yet officially supporting ESLint 10:
- eslint-plugin-react
- eslint-plugin-import
- eslint-plugin-jsx-a11y
- eslint-plugin-react-hooks
This migration depends on the updated `@mui/internal-code-infra` package
from mui-public which contains:
- ESLint 10 compatibility fixes using `@eslint/compat`
- Updated peer dependencies
- Disabled new ESLint 10 rules initially
See: mui/mui-public#1150
- Node.js < v20.19 is no longer supported
- New config lookup algorithm (starts from file directory)
- JSX references are now tracked
- `eslint-env` comments are reported as errors
- ESLint runs successfully with no errors1 parent 5cac916 commit 8dfd19e
3 files changed
Lines changed: 201 additions & 240 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
| |||
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
71 | 75 | | |
72 | 76 | | |
73 | 77 | | |
| |||
205 | 209 | | |
206 | 210 | | |
207 | 211 | | |
208 | | - | |
| 212 | + | |
209 | 213 | | |
210 | 214 | | |
211 | 215 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
| 95 | + | |
95 | 96 | | |
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
99 | | - | |
| 100 | + | |
100 | 101 | | |
101 | 102 | | |
102 | 103 | | |
| |||
127 | 128 | | |
128 | 129 | | |
129 | 130 | | |
130 | | - | |
| 131 | + | |
131 | 132 | | |
132 | 133 | | |
133 | 134 | | |
| |||
0 commit comments