This commit is contained in:
ryan 2025-02-08 23:45:43 -08:00
parent 89eadbd477
commit abe584b1c1
2 changed files with 15 additions and 1 deletions

View File

@ -45,7 +45,7 @@ export default function RootLayout({
{!hasEnvVars ? <EnvVarWarning /> : <HeaderAuth />} {!hasEnvVars ? <EnvVarWarning /> : <HeaderAuth />}
</div> </div>
</nav> </nav>
<div className="flex flex-col gap-20 max-w-5xl p-5"> <div className="flex flex-col gap-20 w-[40%] p-5">
{children} {children}
</div> </div>

View File

@ -0,0 +1,14 @@
'use client';
export default function
useEffect(() => {
const daysChannel = supabase.channel('days')
.on('postgres_changes', { event: 'UPDATE', schema: 'public', table: 'days' }, (payload) => {
setDay(payload.new);
}).subscribe();
return () => {
daysChannel.unsubscribe();
}
}, [supabase])