with bcrypt and sign up page example
• Complete Next-Auth.js Tutorial with S...
Prisma will change the way you code your databases in Next js. This tutorial is about explaining the process of Prisma ORM SQLite based database integration with Next-auth credential-based sign in process. We explained how easy it could be to fetch data from the Sqlite3 database using the Prisma ORM client. Which serves the perfect library for handling the modern databases. Prisma could use Relational as well as non-relational databases as well like MySQL, MariaDB, and lot of other databases. We choose the SQLite3 database for the sake of simplicity and explaining the concept. using Prisma.js with Next.js framework is pretty easy and straight forward. Also, the Prisma studio provided from the Prisma makes our life easier.
This tutorial is one next step toward our previous tutorial series. In the previous tutorial we used the Next-auth.js library for creating the credential-based system. We used the fake credentials with hard coded values of username and password without the use of any back-end database. We fulfil that gap in this tutorial by explaining the way of using the Prisma ORM for backend SQLite database. This backend database is used to query the user model and once user is found we check the password, if password matches, we return that user, otherwise we return null which may result in case of login error on the front-end side, handled by the Next-Auth.js library.
Here are the previous Next.js tutorials links so you could follow along
previous tutorial where we created the Next-auth.js credential based login
• Next Auth credentials example #nextjs...
Next.js tutorial where we created the Layouts for our Next.js project
• How to create Next Js Layouts | Next ...
Link component in Next js Lecture#01
• Nextjs Links #beginners #tutorial #j...
Graph QL in Next js with Apollo Client
• Client-Side Data Collection with Apol...