This is a demo project showcasing how to implement authentication in a Next.js application using NextAuth.js.
First, install the dependencies:
npm installNext, run the database migrations:
npx prisma migrate dev --name initNext, create a .env.local file similar to .env.example with the following variables:
- NEXTAUTH_URL
- NEXTAUTH_SECRET
- GITHUB_ID
- GITHUB_SECRET
Finaly, run the development server:
npm run devOpen http://localhost:3000 with your browser to see the result.
To learn more about NextAuth.js, take a look at the following resources:
This project is licensed under the MIT License.