The issue involves both documentation updates and potential behavioral changes in a core hook.
The issue reports that `useSearchParams()` requires a Suspense boundary despite documentation suggesting otherwise, and an experimental flag mentioned in docs no longer exists. It requires verifying current behavior and updating documentation, with potential changes to the hook's requirements.
https://codesandbox.io/p/devbox/nameless-cookies-go8s7s
useSearchParams from next/navigationnpm run builduseSearchParams() should be wrapped in a suspense boundary at page "/test". Read more: https://nextjs.org/docs/messages/missing-suspense-with-csr-bailoutmissingSuspenseWithCSRBailout to next.config.js. This option does not work, and will cause the build to error out saying that feature/flag doesn't exist.useSearchParams is any different WRT suspense than any other client function like useState. I don't need suspense for them, and I don't see why I should need suspense for useSearchParamsOperating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 24.1.0: Thu Oct 10 21:02:26 PDT 2024; root:xnu-11215.41.3~2/RELEASE_ARM64_T8122
Available memory (MB): 16384
Available CPU cores: 8
Binaries:
Node: 20.17.0
npm: 10.8.2
Yarn: 1.22.22
pnpm: 9.15.0
Relevant Packages:
next: 15.1.3 // Latest available version is detected (15.1.3).
eslint-config-next: 15.1.3
react: 19.0.0
react-dom: 19.0.0
typescript: 5.7.2
Next.js Config:
output: N/A
Not sure, Documentation
next build (local)
The linked codesandbox is on the latest canary, and the issue still appears.
Claim this issue to let others know you're working on it. You'll earn 20 points when you complete it!