refactor routes everywhere
This commit is contained in:
19
frontend/app/(app)/dashboard/page.tsx
Normal file
19
frontend/app/(app)/dashboard/page.tsx
Normal file
@ -0,0 +1,19 @@
|
||||
import { UserButton, currentUser } from "@clerk/nextjs"
|
||||
import { redirect } from "next/navigation"
|
||||
import Dashboard from "@/components/dashboard"
|
||||
import Navbar from "@/components/dashboard/navbar"
|
||||
|
||||
export default async function DashboardPage() {
|
||||
const user = await currentUser()
|
||||
|
||||
if (!user) {
|
||||
redirect("/")
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="w-screen h-screen flex flex-col overflow-hidden overscroll-none">
|
||||
<Navbar />
|
||||
<Dashboard />
|
||||
</div>
|
||||
)
|
||||
}
|
Reference in New Issue
Block a user