high
react-bc-1
automated
confirmed by docs
Applied automatically
ReactDOM.render() is deprecated in React 18 (the app keeps running in legacy React 17 mode) — replace with createRoot().render()
3 files: src/index.jsx, src/legacy/toast.jsx, src/legacy/toast.test.jsx
Transformed 3 file(s); no remaining usages of the old API.
high
react-bc-2
automated
confirmed by docs
Applied automatically
ReactDOM.hydrate() is deprecated in React 18 (legacy mode) — replace with hydrateRoot()
1 file: src/ssr-entry.jsx
Transformed 1 file(s); no remaining usages of the old API.
medium
react-bc-3
automated
Applied automatically
act() from react-dom/test-utils is deprecated — import act from 'react' (available from React 18.3)
1 file: src/legacy/toast.test.jsx
Transformed 1 file(s); no remaining usages of the old API.
medium
react-bc-4
manual
confirmed by docs
Manual action required
Automatic batching: setState calls in timeouts/promises/native handlers are now batched — may affect code or tests relying on intermediate renders
How to fix Review any tests that assert on intermediate render states inside setTimeout, Promise.then, or native event handlers. Wrap those assertions in act() or use flushSync from 'react-dom' to opt out of automatic batching where needed.
4 files: src/App.jsx, src/components/AddItemForm.jsx, src/components/ItemList.jsx, src/components/SyncStatus.jsx
No automated change exists for this rule. Review any tests that assert on intermediate render states inside setTimeout, Promise.then, or native event handlers. Wrap those assertions in act() or use flushSync from 'react-dom' to opt out of automatic batching where needed.
low
react-bc-6
manual
confirmed by docs
Manual action required
Strict Mode now double-invokes effects (mount → unmount → mount) in development to surface side effects
How to fix Audit useEffect, useLayoutEffect, and class lifecycle methods for non-idempotent side effects (network requests, analytics calls, subscriptions). Ensure cleanup functions are implemented so double-invocation does not cause observable problems in development.
1 file: src/index.jsx
No automated change exists for this rule. Audit useEffect, useLayoutEffect, and class lifecycle methods for non-idempotent side effects (network requests, analytics calls, subscriptions). Ensure cleanup functions are implemented so double-invocation does not cause observable problems in development.
low
react-bc-7
manual
Manual action required
ReactDOM.unstable_batchedUpdates is redundant under React 18 automatic batching
How to fix With React 18's automatic batching, explicit calls to unstable_batchedUpdates are no longer needed in most cases. Remove them and verify behaviour. If you need to force synchronous rendering, use flushSync from 'react-dom' instead.
1 file: src/legacy/store.js
No automated change exists for this rule. With React 18's automatic batching, explicit calls to unstable_batchedUpdates are no longer needed in most cases. Remove them and verify behaviour. If you need to force synchronous rendering, use flushSync from 'react-dom' instead.
medium
react-bc-8
manual
confirmed by docs
Manual action required
ReactDOM.unmountComponentAtNode() is deprecated in React 18 — call root.unmount() on the root returned by createRoot()
How to fix Keep the root returned by createRoot(container) and call root.unmount() instead of unmountComponentAtNode(container). In tests, unmount the root the test created (React Testing Library unmounts automatically).
1 file: src/legacy/toast.jsx
No automated change exists for this rule. Keep the root returned by createRoot(container) and call root.unmount() instead of unmountComponentAtNode(container). In tests, unmount the root the test created (React Testing Library unmounts automatically).
low
react-bc-12
manual
confirmed by docs
Manual action required
Tests that render with react-dom directly need globalThis.IS_REACT_ACT_ENVIRONMENT = true under React 18
How to fix In the test setup file (e.g. setupTests.js / jest.setup.js), set globalThis.IS_REACT_ACT_ENVIRONMENT = true; so React 18 knows it runs in an act-aware test environment. React Testing Library ≥ 13 sets this automatically for tests that use it.
1 file: src/legacy/toast.test.jsx
No automated change exists for this rule. In the test setup file (e.g. setupTests.js / jest.setup.js), set globalThis.IS_REACT_ACT_ENVIRONMENT = true; so React 18 knows it runs in an act-aware test environment. React Testing Library ≥ 13 sets this automatically for tests that use it.