15 lines
336 B
TypeScript
15 lines
336 B
TypeScript
|
|
// src/auth.ts
|
||
|
|
import NextAuth from "next-auth";
|
||
|
|
import Google from "next-auth/providers/google";
|
||
|
|
|
||
|
|
export const { handlers, auth, signIn, signOut } = NextAuth({
|
||
|
|
providers: [
|
||
|
|
Google({
|
||
|
|
clientId: process.env.GOOGLE_CLIENT_ID!,
|
||
|
|
clientSecret: process.env.GOOGLE_CLIENT_SECRET!,
|
||
|
|
}),
|
||
|
|
|
||
|
|
],
|
||
|
|
|
||
|
|
// ...callbacks 등등
|
||
|
|
});
|