- Updated `env.example` to include NextAuth configuration for authentication. - Added `next-auth` dependency to manage user sessions. - Introduced `User` model in Prisma schema with fields for user details and password hashing. - Integrated `AuthProvider` in layout for session management across the app. - Enhanced `Header` component with `AuthButton` for user authentication controls.
8 lines
198 B
TypeScript
8 lines
198 B
TypeScript
'use client'
|
|
|
|
import { SessionProvider } from "next-auth/react"
|
|
|
|
export function AuthProvider({ children }: { children: React.ReactNode }) {
|
|
return <SessionProvider>{children}</SessionProvider>
|
|
}
|