8 lines
289 B
TypeScript
8 lines
289 B
TypeScript
import { PrismaAdapter } from '@lucia-auth/adapter-prisma'
|
|
import { Lucia } from 'lucia'
|
|
import prisma from '../prisma/client'
|
|
|
|
export const auth = new Lucia<object, { username: string, displayName: string }>(new PrismaAdapter(prisma.session, prisma.user))
|
|
|
|
export type Auth = typeof auth
|