Files
full-stack-fastapi/frontend/src/routes/_layout/index.tsx
2025-12-08 19:27:08 +01:00

32 lines
649 B
TypeScript

import { createFileRoute } from "@tanstack/react-router"
import useAuth from "@/hooks/useAuth"
export const Route = createFileRoute("/_layout/")({
component: Dashboard,
head: () => ({
meta: [
{
title: "Dashboard - FastAPI Cloud",
},
],
}),
})
function Dashboard() {
const { user: currentUser } = useAuth()
return (
<div>
<div>
<h1 className="text-2xl truncate max-w-sm">
Hi, {currentUser?.full_name || currentUser?.email} 👋
</h1>
<p className="text-muted-foreground">
Welcome back, nice to see you again!!!
</p>
</div>
</div>
)
}