Roll your own auth boilerplate, REST API - Next.js
Find a file
2023-12-20 23:12:26 +01:00
.vscode init commit 2023-09-17 23:04:39 +02:00
public init commit 2023-09-17 23:04:39 +02:00
src chore: added middleware and upgraded packages 2023-12-20 23:12:26 +01:00
.editroconfig init commit 2023-09-17 23:04:39 +02:00
.env.local.example init commit 2023-09-17 23:04:39 +02:00
.eslintignore init commit 2023-09-17 23:04:39 +02:00
.eslintrc.json init commit 2023-09-17 23:04:39 +02:00
.gitignore init commit 2023-09-17 23:04:39 +02:00
.prettierignore init commit 2023-09-17 23:04:39 +02:00
components.json init commit 2023-09-17 23:04:39 +02:00
next.config.js init commit 2023-09-17 23:04:39 +02:00
package.json chore: added middleware and upgraded packages 2023-12-20 23:12:26 +01:00
pnpm-lock.yaml chore: added middleware and upgraded packages 2023-12-20 23:12:26 +01:00
postcss.config.js init commit 2023-09-17 23:04:39 +02:00
README.md chore: added middleware and upgraded packages 2023-12-20 23:12:26 +01:00
tailwind.config.ts init commit 2023-09-17 23:04:39 +02:00
tsconfig.json init commit 2023-09-17 23:04:39 +02:00

Roll Your Own Auth

Roll Your Own Auth is a TypeScript project that provides a flexible authentication system for your web applications.

This boilerplate is one of incoming boilerplates, this one leverages Next.js making requests to a REST API that implements authentication using session-based storage in Redis, the user id is then securely stored in HTTP-only cookies.

This specific project requires the following REST API

Getting Started

  1. Setup environment variables
  2. Install dependencies
pnpm i
  1. Start your server
pnpm dev

Open http://localhost:3000 with your browser to see the result.

This project uses shadcn/ui which provides UI components ready to copy paste manually or via their CLI, it uses radix-ui.

Todo

  • Cleanup code
  • Add middleware
  • Handle server side errors