Initialize Supabase Next app

This commit is contained in:
2026-05-23 13:24:39 -06:00
parent c9038a8f3c
commit 5bed4dcf11
56 changed files with 9851 additions and 3 deletions

View File

@@ -0,0 +1,17 @@
"use client";
import { createClient } from "@/lib/supabase/client";
import { Button } from "@/components/ui/button";
import { useRouter } from "next/navigation";
export function LogoutButton() {
const router = useRouter();
const logout = async () => {
const supabase = createClient();
await supabase.auth.signOut();
router.push("/auth/login");
};
return <Button onClick={logout}>Logout</Button>;
}