You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Uncaught TypeError: create is not a function
at react-stack-bottom-frame (react-dom-client.development.js:22509:20)
at runWithFiberInDEV (react-dom-client.development.js:543:16)
at commitHookEffectListMount (react-dom-client.development.js:10758:29)
at commitHookPassiveMountEffects (react-dom-client.development.js:10878:11)
at reconnectPassiveEffects (react-dom-client.development.js:12802:11)
at recursivelyTraverseReconnectPassiveEffects (react-dom-client.development.js:12774:9)
at reconnectPassiveEffects (react-dom-client.development.js:12849:11)
at doubleInvokeEffectsOnFiber (react-dom-client.development.js:15696:13)
at runWithFiberInDEV (react-dom-client.development.js:543:16)
at recursivelyTraverseAndDoubleInvokeEffectsInDEV (react-dom-client.development.js:15656:17)
at commitDoubleInvokeEffectsInDEV (react-dom-client.development.js:15705:7)
at flushPassiveEffects (react-dom-client.development.js:15470:13)
at eval (react-dom-client.development.js:15324:11)
at MessagePort.performWorkUntilDeadline (scheduler.development.js:44:48)
The expected behavior
Ideally not crash - or crash with a better error message?
In #15197 the reviews seemed to pointed towards a dev-only warning, rather than an invariant.
Re-opening of #15194 because the stalebot closed it.
The text was updated successfully, but these errors were encountered:
## Summary
Fixes#32354.
Re-creation of #15197: adds a dev-only warning if `create == null` to
the three `use*Effect` functions:
* `useEffect`
* `useInsertionEffect`
* `useLayoutEffect`
Updates the warning to match the same text given in the
`react/exhaustive-deps` lint rule.
## How did you test this change?
I applied the changes manually within `node_modules/` on a local clone
of
https://github.com/JoshuaKGoldberg/repros/tree/react-use-effect-no-arguments.
Please pardon me for opening a PR addressing a not-accepted issue. I was
excited to get back to #15194 -> #15197 now that I have time. 🙂
---------
Co-authored-by: lauren <poteto@users.noreply.github.com>
DiffTrain build for [192555b](192555b)
## Summary
Fixes#32354.
Re-creation of #15197: adds a dev-only warning if `create == null` to
the three `use*Effect` functions:
* `useEffect`
* `useInsertionEffect`
* `useLayoutEffect`
Updates the warning to match the same text given in the
`react/exhaustive-deps` lint rule.
## How did you test this change?
I applied the changes manually within `node_modules/` on a local clone
of
https://github.com/JoshuaKGoldberg/repros/tree/react-use-effect-no-arguments.
Please pardon me for opening a PR addressing a not-accepted issue. I was
excited to get back to #15194 -> #15197 now that I have time. 🙂
---------
Co-authored-by: lauren <poteto@users.noreply.github.com>
DiffTrain build for [192555b](192555b)
React version: 19.0.0
Steps To Reproduce
useEffect()
- note the lack of argumentsLink to code example:
The current behavior
The expected behavior
Ideally not crash - or crash with a better error message?
In #15197 the reviews seemed to pointed towards a dev-only warning, rather than an invariant.
Re-opening of #15194 because the stalebot closed it.
The text was updated successfully, but these errors were encountered: