Fix build: wrap useSearchParams in Suspense boundary
Next.js requires useSearchParams() to be inside a Suspense boundary for static page generation. Wraps the new integration page component. Made-with: Cursor
This commit is contained in:
parent
a975043670
commit
95a672a6cb
1 changed files with 8 additions and 0 deletions
|
|
@ -34,6 +34,14 @@ type ConfigField = {
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function NewIntegrationPage() {
|
export default function NewIntegrationPage() {
|
||||||
|
return (
|
||||||
|
<React.Suspense fallback={<div className="flex items-center justify-center py-20"><Loader2 className="size-6 animate-spin text-muted-foreground" /></div>}>
|
||||||
|
<NewIntegrationForm />
|
||||||
|
</React.Suspense>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
function NewIntegrationForm() {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const searchParams = useSearchParams();
|
const searchParams = useSearchParams();
|
||||||
const preselectedProvider = searchParams.get("provider") || "";
|
const preselectedProvider = searchParams.get("provider") || "";
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue