rsnext/errors/missing-suspense-with-csr-bailout.mdx

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

18 lines
824 B
Text
Raw Normal View History

---
title: Missing Suspense with CSR Bailout
---
#### Why This Error Occurred
Certain methods like `useSearchParams()` opt Next.js into client-side rendering. Without a suspense boundary, this will opt the entire page into client-side rendering, which is likely not intended.
#### Possible Ways to Fix It
Make sure that the method is wrapped in a suspense boundary. This way Next.js will only opt the component into client-side rendering up to the suspense boundary.
> Note: There's an option `experimental.missingSuspenseWithCSRBailout` to disable the bailout behavior while you are investigating the missing suspense boundary. But it will be removed in next major version as this is a performance de-opt.
### Useful Links
- [`useSearchParams`](https://nextjs.org/docs/app/api-reference/functions/use-search-params)