Skip to content

Repository files navigation

⚔️ Codelords Stack

NPM version

The full-featured Next.js starter CLI built for serious developers by Chillenow

Codelords Stack helps you bootstrap modern web apps using Next.js, Prisma, PostgreSQL, and Tailwind CSS — all configurable via an interactive CLI.
Use it to kick off production-ready projects in seconds.


✨ Features

  • ⚡️ Next.js 16 with App Router
  • 🎨 Tailwind CSS pre-configured
  • 🧬 Prisma + PostgreSQL database setup
  • 🔐 Optional Better Auth (Email/Password login)
  • 💳 Optional LemonSqueezy integration (WIP 🚧)
  • /status page to verify feature status
  • 🛠️ CLI with npx codelords-stack command

🚀 Quick Start

Use npx to instantly create your project:

npx codelords-stack

Then follow the interactive prompts:

  • 📦 Name your project
  • 🔐 Select optional features
  • 🏗 Scaffolds everything automatically

After generation:

⚙️ Database Setup

Prisma is configured to use PostgreSQL. Your connection string is located in .env:

DATABASE_URL="postgresql://USER:PASSWORD@localhost:5432/postgres?schema=database_name_db"

Run after installing:

pnpm prisma generate
pnpm prisma db push

You can find the Prisma schema at prisma/schema.prisma.

To create a new migration, modify schema.prisma and then run:

 pnpm prisma migrate dev --name name_of_migration;

To reset database run: [⚠️ this command will be remove all the tables on your connected database]

 pnpm prisma migrate reset

to push the schema to the database, run the following command:

 pnpm prisma db push

⚙️ Run after database is configured:

cd your-project-name
pnpm dev

Open http://localhost:3000 in your browser.


📂 Folder Structure

.
├── app/                      # App router structure
│   └── status/               # Status page (DB check)
├── lib/
│   └── prisma.ts             # Dynamic Prisma client
├── prisma/
│   └── schema.prisma         # Prisma DB schema
├── .env                      # Created from .env.example
├── tailwind.config.ts
├── tsconfig.json
└── ...

🧪 Stack Status Page

Visit http://localhost:3000/status to check:

  • ✅ PostgreSQL database connectivity
  • (Coming soon) other feature statuses

🔐 Optional Features

You can toggle optional integrations during CLI setup:

  • Better Auth
    Adds full authentication flow with email/password login, registration, and session management. Includes customizable user roles (default: user, admin).

  • LemonSqueezy
    Adds premium feature monetization with payment hooks.

You can always add these manually later, or modify your template.


🔧 Customizing User Roles

Roles are stored as strings for flexibility. Default roles: user, admin

To customize roles in your generated project:

  1. Edit prisma/schema.prisma - change the role field default value
  2. Edit src/lib/auth.ts - update the additionalFields.role configuration
  3. Run pnpm prisma generate && pnpm prisma db push

🤖 CLI Usage

You can run the CLI directly with:

npx codelords-stack

🧠 About

Codelords Stack is crafted by Chillenow to make professional-grade web app creation accessible and fast.

We use this stack in production for our own apps — and now, you can too.

💬 Follow us on Instagram or X for updates.

💸 Wanna tip? you can via Github Sponsors Github Sponsors


🏷 License

MIT

About

Codelords Stack helps you bootstrap modern web apps using Next.js, Prisma, PostgreSQL, and Tailwind CSS — all configurable via an interactive CLI. Use it to kick off production-ready projects in seconds.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages