first commit

This commit is contained in:
Leonardo
2026-02-18 22:36:45 -03:00
parent ec6b6ef53a
commit 676042268b
122 changed files with 26354 additions and 1615 deletions
+19
View File
@@ -0,0 +1,19 @@
import { ref, onMounted } from 'vue'
import { supabase } from '@/lib/supabase/client'
const user = ref(null)
export function useAuth() {
const init = async () => {
const { data } = await supabase.auth.getSession()
user.value = data.session?.user || null
}
supabase.auth.onAuthStateChange((_, session) => {
user.value = session?.user || null
})
onMounted(init)
return { user }
}