Files
got-gaming/types/next-auth.d.ts

28 lines
425 B
TypeScript

import { Role } from "@/prisma/generated/prisma/client";
import "next-auth";
declare module "next-auth" {
interface User {
id: string;
username: string;
role: Role;
}
interface Session {
user: {
id: string;
email: string;
username: string;
role: Role;
};
}
}
declare module "next-auth/jwt" {
interface JWT {
id: string;
username: string;
role: Role;
}
}