Giter Site home page Giter Site logo

patelvivekdev / authjs-template Goto Github PK

View Code? Open in Web Editor NEW
15.0 1.0 0.0 3.1 MB

A template repo for starting authentication in your upcoming Next.js application. Used Drizzle, Auth.js(Next-Auth), Turso.

Home Page: https://authjs-template.patelvivek.dev

License: MIT License

Nix 0.12% JavaScript 0.23% CSS 0.66% TypeScript 98.95% Shell 0.03%
authjs drizzle-orm libsql nextjs react turso 2fa passkeys webauthn authjs-template acertinityui magicui next-auth two-factor-authentication

authjs-template's Introduction

AuthJs Template

A template repo for starting authentication in your upcoming Next.js application. Used Drizzle, Auth.js(Next-Auth), Turso.

Image

What's inside?

  • How to setup Credentials login with username/password in NextJs.
  • How to setup Two factor in NextJs.
  • How to setup Passkey in NextJs.
  • How to setup Oauth Login in NextJs.
  • How to Link accounts in NextJs.

All these with Next-auth(AuthJs v5).


Basic

  • Register | Public
  • Login | Public
  • Credentials Login | Public
  • Social Login(Google, Github) | Public
  • Email Verification | Public

Password Reset

  • Password Reset (email link) | Public
  • change password(Email user can change password) | Protected
  • Add Password(Oauth user can set Password.) | Protected

Profile Update

  • Profile Update | Protected
  • Profile Picture Update | Protected
  • Email Update | Protected
  • Username Update | Protected
  • Delete Account | Protected

Link Accounts

  • Account linking | Protected
  • Account Unlinking | Protected

Two Factor Authentication

  • Two Factor - Register with QRCode | Protected
  • Two Factor - Verify after register | Protected
  • Two Factor - Used After login(Oauth as well as Credentials) | Public
  • Add Backup options(Verify using email)
  • Disable Two Factor.

Passkey/ Passwordless Login

  • Passkey/ Passwordless Login

Role Based Access

  • Role Based Access | Protected

Here I used my domain to select admin user. After that admin can another admin

User Management (Admin)

  • Admin Dashboard
  • Permission

Database sessions

Emails

  • Send email for every account change event and store the history.

Links

Open In IDX

Open in IDX
Stars Forks Issues
Made with ❤️ by Vivek Patel

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.