Add todo example, remove yarn, change schema structure, update readme

This commit is contained in:
Aman Varshney
2025-03-24 00:04:53 +05:30
parent 5076bf4176
commit 4cc13bf382
42 changed files with 525 additions and 443 deletions

View File

@@ -3,39 +3,27 @@ import { ModeToggle } from "./mode-toggle";
import UserMenu from "./user-menu";
export default function Header() {
const links = [
{ to: "/", label: "Home" },
{ to: "/dashboard", label: "Dashboard" },
];
return (
<div>
<div className="flex flex-row items-center justify-between px-2 py-1">
<div className="flex gap-4 text-lg">
<Link
to="/"
activeProps={{
className: "font-bold",
}}
activeOptions={{ exact: true }}
>
Home
</Link>
<Link
to="/todos"
activeProps={{
className: "font-bold",
}}
activeOptions={{ exact: true }}
>
Todos
</Link>
<Link
to="/dashboard"
activeProps={{
className: "font-bold",
}}
activeOptions={{ exact: true }}
>
Dashboard
</Link>
</div>
<div className="flex flex-row items-center gap-2">
<nav className="flex gap-4 text-lg">
{links.map(({ to, label }) => (
<Link
key={to}
to={to}
activeProps={{ className: "font-bold" }}
activeOptions={{ exact: true }}
>
{label}
</Link>
))}
</nav>
<div className="flex items-center gap-2">
<ModeToggle />
<UserMenu />
</div>