React 16.10 broke Next.js/SSR applications
See original GitHub issueDo you want to request a feature or report a bug? Bug
What is the current behavior?
React 16.10.0 has broken all Next.js applications (and potentially other SSR solutions).
It appears you cannot hydrate
in conjunction with a client-side <Suspense>
component.
Expected to have a hydrated suspense instance. This error is likely caused by a bug in React. Please file an issue.
CodeSandbox: https://codesandbox.io/s/i66g1
What is the expected behavior?
Not entirely sure – I’m opening this issue to discuss. The provided example worked in React 16.9.0 (and prior releases containing Suspense).
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
react@16.10.0
/react-dom@16.10.0
is broken.
react@16.9.0
/react-dom@16.9.0
works.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:24
- Comments:10 (6 by maintainers)
This is now fixed in v16.10.1.
I believe technically we don’t support conditionally rendering a Suspense boundary when server rendering. It just happened to (accidentally) work before.
We’ll either fix so it matches the old behavior or provide a more graceful error or fallback behavior.