This PR contains the following updates:
| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| eslint-plugin-react-hooks (source) | ^5.2.0 → ^7.1.1 |
Release Notes
facebook/react (eslint-plugin-react-hooks)
v7.1.1
Note: 7.1.0 accidentally removed the component-hook-factories rule, causing errors for users who referenced it in their ESLint config. This is now fixed.
- Add deprecated no-op
component-hook-factoriesrule for backwards compatibility. (@mofeiZ in #36307)
v7.1.0
This release adds ESLint v10 support, improves performance by skipping compilation for non-React files, and includes compiler lint improvements including better set-state-in-effect detection, improved ref validation, and more helpful error reporting.
- Add ESLint v10 support. (@nicolo-ribaudo in #35720)
- Skip compilation for non-React files to improve performance. (@josephsavona in #35589)
- Fix exhaustive deps bug with Flow type casting. (@jorge-cab in #35691)
- Fix
useEffectEventchecks in component syntax. (@jbrown215 in #35041) - Improved
set-state-in-effectvalidation with fewer false negatives. (@jorge-cab in #35134, @josephsavona in #35147, @jackpope in #35214, @chesnokov-tony in #35419, @jsleitor in #36107) - Improved ref validation for non-mutating functions and event handler props. (@josephsavona in #35893, @kolvian in #35062)
- Compiler now reports all errors instead of stopping at the first. (@josephsavona in #35873–#35884)
- Improved source locations and error display in compiler diagnostics. (@nathanmarks in #35348, @josephsavona in #34963)
v7.0.1
- Disallowed passing inline
useEffectEventvalues as JSX props to guard against accidental propagation. (#34820 by @jf-eirinha) - Switch to
export =so eslint-plugin-react-hooks emits correct types for consumers in Node16 ESM projects. (#34949 by @karlhorky) - Tightened the typing of
configs.flatso theconfigsexport is always defined. (#34950 by @poteto) - Fix named import runtime errors. (#34951, #34953 by @karlhorky)
v7.0.0
This release slims down presets to just 2 configurations (recommended and recommended-latest), and all compiler rules are enabled by default.
- Breaking: Removed
recommended-latest-legacyandflat/recommendedconfigs. The plugin now providesrecommended(legacy and flat configs with all recommended rules), andrecommended-latest(legacy and flat configs with all recommended rules plus new bleeding edge experimental compiler rules). (@poteto in #34757)
v6.1.1
Note: 6.1.0 accidentally allowed use of recommended without flat config, causing errors when used with ESLint v9's defineConfig() helper. This has been fixed in 6.1.1.
- Fix
recommendedconfig for flat config compatibility. Therecommendedconfig has been converted to flat config format. Non-flat config users should userecommended-legacyinstead. (@poteto in #34700) - Add
recommended-latestandrecommended-latest-legacyconfigs that include React Compiler rules. (@poteto in #34675) - Remove unused
NoUnusedOptOutDirectivesrule. (@poteto in #34703) - Remove
hermes-parserand dependency. (@poteto in #34719) - Remove
@babel/plugin-proposal-private-methodsdependency. (@ArnaudBarre and @josephsavona in #34715) - Update for Zod v3/v4 compatibility. (@kolian and @josephsavona in #34717)
v6.1.0
Note: Version 6.0.0 was mistakenly released and immediately deprecated and untagged on npm. This is the first official 6.x major release and includes breaking changes.
- Breaking: Require Node.js 18 or newer. (@michaelfaith in #32458)
- Breaking: Flat config is now the default
recommendedpreset. Legacy config moved torecommended-legacy. (@michaelfaith in #32457) - New Violations: Disallow calling
usewithin try/catch blocks. (@poteto in #34040) - New Violations: Disallow calling
useEffectEventfunctions in arbitrary closures. (@jbrown215 in #33544) - Handle
React.useEffectin addition touseEffectin rules-of-hooks. (@Ayc0 in #34076) - Added
react-hookssettings config option that to acceptadditionalEffectHooksthat are used across exhaustive-deps and rules-of-hooks rules. (@jbrown215) in #34497
v6.0.0
Accidentally released. See 6.1.0 for the actual changes.
Configuration
📅 Schedule: (UTC)
- Branch creation
- At any time (no schedule defined)
- Automerge
- At any time (no schedule defined)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
- If you want to rebase/retry this PR, check this box
This PR was generated by Mend Renovate. View the repository job log.