page.tsx (420B)
1 import { redirect } from "next/navigation" 2 3 export default async function DashboardPage({ 4 searchParams, 5 }: { 6 searchParams: Promise<{ [key: string]: string | string[] | undefined }> 7 }) { 8 const teamId = (await searchParams).team as string | undefined 9 10 // Redirect to overview with team parameter 11 const redirectUrl = teamId ? `/dashboard/overview?team=${teamId}` : "/dashboard/overview" 12 13 redirect(redirectUrl) 14 }