Repository navigation
Conversation
🦋 Changeset detectedLatest commit: 762d6d8 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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 |
|
92cbc6c to
06025a9
Compare
06025a9 to
18b7749
Compare
18b7749 to
762d6d8
Compare
There was a problem hiding this comment.
🟢 Approval recommended
The focused changes preserve production behavior and include targeted regression coverage; no blocking issues were identified.
No open issues 🎉
What changed in this PR
Continues the React Compiler rollout by enabling optimization for the shared ButtonBase component without changing public APIs.
Changes:
- Enables React Compiler for
ButtonBase. - Moves development-only validation after commit and adds regression coverage.
- Adds a minor-release changeset.
| File | Description |
|---|---|
| packages/react/src/Button/ButtonBase.tsx | Runs validation through useDevOnlyEffect. |
| packages/react/src/Button/__tests__/Button.test.tsx | Tests validation after ref attachment. |
| packages/react/script/react-compiler.mjs | Removes the ButtonBase compiler exclusion. |
| .changeset/react-compiler-button-base.md | Documents the rendering performance improvement. |
Review effort: Balanced
|
Integration test results from github/github-ui PR:
CI check runs linting, type checking, and unit tests. Check the workflow logs for specific failures. VRT check ensures that when visual differences are detected, the PR cannot proceed until someone acknowledges the changes by adding the "visual difference acknowledged" label. Need help? If you believe this failure is unrelated to your changes, please reach out to the Primer team for assistance. |
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: e632d4e3-54d2-4423-9888-8e37b00494a3
762d6d8 to
ec89f27
Compare
Follow up to #8562.
This PR enables React Compiler for
ButtonBase, which is shared byButton,IconButton, andLinkButton. We move development-only validation intouseDevOnlyEffectso it reads the attached DOM ref after commit instead of during render.Production interactions and public APIs stay unchanged.
Changelog
New
Changed
ButtonBase.Removed
Rollout strategy
Selected
minorfor the compiler rollout, consistent with the earlier entries in this stack. No consumer migration is needed.