Conversation
🦋 Changeset detectedLatest commit: 3bd3aeb The changes in this PR will be included in the next version bump. This PR includes changesets to release 8 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
🟢 No design token changes found |
🟢 Unit test coverage changes foundUnit test coverage has been updated through this PR. Changes: 0 new tests, 0 removed tests, 0 improved, 2 decreased
|
🟢 No visual differences foundOur visual comparison tests did not find any differences in the UI. |
There was a problem hiding this comment.
Pull Request Overview
This PR migrates the project from ESLint v8 to ESLint v9 with flat config support. The main changes include:
- Replacing
.eslintrc.jsfiles witheslint.config.mjsflat config files - Upgrading ESLint and related plugins to v9-compatible versions
- Converting CommonJS imports to ESM imports (e.g.,
import clsx from 'clsx'→import {clsx} from 'clsx') - Vendoring the
i18n-text/no-enrule due to ESLint v9 incompatibility - Refactoring internal component function names for consistency
- Migrating the Playwright test generator script to ESM
Reviewed Changes
Copilot reviewed 186 out of 188 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
eslint.config.mjs |
New flat config replacing root .eslintrc.js with vendored i18n rule integration |
packages/repo-configs/custom-lint-rules/no-english-text.js |
Vendored i18n rule for ESLint v9 compatibility |
packages/react/src/**/*.tsx |
Updated clsx imports and component naming conventions |
packages/e2e/scripts/playwright/*.ts |
Migrated test generator from CommonJS to ESM |
package.json |
Upgraded ESLint and plugins to v9-compatible versions |
.eslintrc.js (deleted) |
Removed legacy config files across all packages |
danielguillan
left a comment
There was a problem hiding this comment.
This looks great! No issues detected when running locally.
Summary
Towards https://github.com/github/primer/issues/5926
Upgrades our ESLint toolchain to v9, which includes a number of breaking changes.
This PR looks to minimize the blast zone of changes to only what's necessary. Follow up PR's will be required to upgrade some adjacent ESLint plugins.
For benchmarking purposes... ESLint (v8) vs ESLint (v9):
Includes BiomeJS as an experiment only. More on that another time.
List of notable changes:
_prefixing of component names is now deemed an error byrules-of-hooks. All instances replaced.i18nplugin, as it's now turned off ingithub/recommendedbut we still need it in BrandWhat should reviewers focus on?
Steps to test:
Contributor checklist:
update snapshotslabel to the PR)Reviewer checklist: