Skip to content

Client components need to be wrapped in a <Suspense> boundary ? #846

Answered by franky47
mtlaso asked this question in General
Discussion options

You must be logged in to vote

Adding the 'use client' directive to the page.tsx file is the immediate fix to get things working if you are defining components that use client-side features (like nuqs or React hooks), but the steps below indicate the optimal approach to get better UX: separating server and client files (and moving client side code as low down the tree as possible to pre-render the outer shell).

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@mtlaso
Comment options

@franky47
Comment options

@mtlaso
Comment options

Answer selected by mtlaso
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants