A modern, secure authentication boilerplate using Lucia, Drizzle ORM, React, and more — designed with clean UI principles inspired by shadcn/ui and powered by TypeScript-friendly tools.
- 🔐 Authentication with Lucia
- 🗃️ Type-safe database access using Drizzle ORM
- 📄 Schema-based form validation using React Hook Form + Zod
- 🌐 Routing with React Router v7
- 🎨 Tailwind CSS for utility-first styling (ShadCN-inspired)
- ⚡️ Built with performance and developer experience in mind
| Tool | Description |
|---|---|
| Lucia | A modern learning resource and library to implement auth from scratch. |
| Drizzle ORM | A type-safe, lightweight, SQL-centric ORM for TypeScript/JavaScript. |
| React Hook Form | Performant and easy-to-use form library. |
| Zod | TypeScript-first schema declaration and validation library. |
| React Router v7 | A routing library for React, flexible and modern. |
| Tailwind CSS | Utility-first CSS framework for fast UI development. |
- Node.js (>=18)
- A modern package manager:
pnpm,npm, oryarn
pnpm installRename .env.example to .env and fill in the required environment variables before running the project:
mv .env.example .envYou can run these scripts via your package manager:
| Script | Description |
|---|---|
pnpm dev |
Start development server with React Router |
pnpm build |
Build the React Router server and client bundles |
pnpm start |
Serve the built React Router server |
pnpm typecheck |
Generate React Router types and run TypeScript check |
pnpm db-generate |
Generate Drizzle ORM migration files |
pnpm db-push |
Push migrations and update database schema |
Example:
pnpm devsrc/
├── components/ # Reusable UI components
├── pages/ # Route-based components like Home, Login, Signup
├── db/ # Drizzle ORM schema and database logic
├── lib/ # Utility functions, auth helpers, etc.
└── main.tsx # Entry point
This project is open source and available under the MIT License.
Let me know if you want to:
- Add a live demo link
- Include deployment instructions (like Vercel/Netlify)
- Include
.env.exampleor database setup instructions
I can also help you auto-generate a logo or badge-style headers if you want a more polished README.