If you hit this error, you're trying to use hooks after upgrading react to 16.7, but you haven't upgraded react-dom to the same version!
The experience could be improved by checking for dispatcher.getState here https://github.com/facebook/react/blob/504576306461a5ff339dc99691842f0f35a8bf4c/packages/react/src/ReactHooks.js#L17, and throwing an error that explains your -dom package is out of date.
Closing because there is no real bug here, just hope somebody finds this useful
Haha thanks
I'm using react@next ("^16.7.0-alpha.0"), but with TypeScript and I hit this error oO
UPDATE: I believe my issue is because "react-konva" is not updated.
Thx! I had similar problem
I got this error when using Jest.
and i update react-test-renderer then solved.
yarn add -D react-test-renderer@next
"react": "^16.7.0-alpha.0",
"react-dom": "^16.7.0-alpha.0",
"react-test-renderer": "^16.7.0-alpha.0",
LOL: just stumbled on this. thanks @ericvicenti
More issues like this please! 馃槏
Had a similar issue but I had to specify exact version 16.7.0-alpha.2 as a dep rather than the default ^16.7.0-alpha.2 that would resolve to 16.7.0 in my lockfile.
Most helpful comment
Had a similar issue but I had to specify exact version
16.7.0-alpha.2as a dep rather than the default^16.7.0-alpha.2that would resolve to16.7.0in my lockfile.