An open API service indexing awesome lists of open source software.

https://github.com/yash0z/hono-nextauth

Hono integration with NextAuth(Authjs)
https://github.com/yash0z/hono-nextauth

authjs authjs-template hono nextjs

Last synced: about 1 year ago
JSON representation

Hono integration with NextAuth(Authjs)

Awesome Lists containing this project

README

          

# Hono.js with NextAuth.js Integration

This project demonstrates how to integrate **Hono.js** with **NextAuth.js** for authentication in a Next.js application. Hono.js serves as the backend, providing lightweight, high-performance API handling, while NextAuth.js manages secure authentication with various providers.

## Getting Started

###

### 1. Project Setup

```
git clone https://github.com/Yash0z/Hono-NextAuth.git
cd Hono-NextAuth
npm install
```

### 2. Env configuration

Create a .env.local file in the Next.js project root and configure environment variables for your authentication providers:

```
AUTH_URL = ""
AUTH_SECRET = ""
GITHUB_ID = ""
GITHUB_SECRET = ""
AUTH_GOOGLE_ID = ""
AUTH_GOOGLE_SECRET = ""
```

You can add details for more providers (e.g. Apple, Twitter, Discord, Email, etc).

#

### Live Example

url : hono-next-auth-levf.vercel.app/

#

### Thank You :>