useSearchParams() should be wrapped in a suspense boundary
Unanswered
American black bear posted this in #help-forum
American black bearOP
Hey all, been using Next.js and am creating a blog and just created a 'blog' directory with the page.tsx and I keep getting the error in the title. The strange thing is, all I have in the file is :
I have removed all other files in the directory and still get ther error. Also rebuilt the .next and node_modules folder. Still no luck.
Has anyone else had this issue before? Any ideas on what it could be?
Thanks!
export default async function BlogListServerPage() {
return (
<div className="flex flex-col items-center justify-center w-full h-screen">
<h1 className="text-4xl font-bold">Blog List</h1>
<p className="mt-4 text-lg">This is the blog list page.</p>
</div>
)
}
I have removed all other files in the directory and still get ther error. Also rebuilt the .next and node_modules folder. Still no luck.
Has anyone else had this issue before? Any ideas on what it could be?
Thanks!
2 Replies
Giant panda
Wrap this component in suspense
American black bearOP
Done, and still nothing. Fails to build.