-
Notifications
You must be signed in to change notification settings - Fork 48.8k
[eslint-plugin-react-hooks] update fbsource build #33104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the build output for fbsource by syncing the lint rules directly via including the eslint-plugin-react-hooks in the build artifacts.
- Updated the workflow to copy rather than move eslint-plugin-react-hooks for the standard build.
- Introduced a separate handling for fbsource that includes the full package (including package.json) for dependency management.
In order to sync the lint rules directly to internal, include the eslint plugin in the build output for fbsource.
Comparing: 4c4a57c...69ca0d2 Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the fbsource build process to include the eslint-plugin-react-hooks in the build output, ensuring internal sync with lint rules.
- Replaces file moves with file copies for eslint-plugin-react-hooks.
- Adds a new step to copy the entire eslint-plugin-react-hooks package (including package.json) to the fbsource vendor folder.
In order to sync the lint rules directly to internal, include the eslint plugin in the build output for fbsource.
Noop detection for xplat syncs broke because `eslint-plugin-react-hooks` uses versions like: - `0.0.0-experimental-d85f86cf-20250514` But xplat expects them to be of the form: - `19.2.0-native-fb-63d664b2-20250514` This PR fixes the noop by ignoring `eslint-plugin-react-hooks/package.json` changes. This means we won't create a sync if only that package.json changes, but that should be rare and we can follow up with better detection if needed. [Example failed action](https://github.com/facebook/react/actions/runs/15032346805/job/42247414406): <img width="1031" alt="Screenshot 2025-05-15 at 11 31 17 AM" src="https://github.com/user-attachments/assets/d902079c-1afe-4e18-af1d-25e60e28929e" /> I believe the regression was caused by #33104
In order to sync the lint rules directly to internal, include the eslint plugin in the build output for fbsource.