Fail build when enter pages opts into client-side rendering #64245
bitttttten
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Goals
When an entire page gets deopted into client-side rendering, it would be nice to error on the build.
Background
Currently when using
useSearchParams
without a Suspense boundary, Next.JS will only warn you when building your app. This warning is not visible in development, so you can deploy an app where you page has deopted out of server-side rendering without even knowing.Proposal
Option a: error by default if opt'd out of server side rendering. This adds more friction.
Option b: allow a config option like
experimental.failOnCSRBailout
.Beta Was this translation helpful? Give feedback.
All reactions