create-baf-app
v1.0.1
Published
Create production-ready Express + TypeScript apps with Prisma, Socket.IO, Redis & more
Maintainers
Readme
create-baf-app
Create production-ready Express + TypeScript applications with a single command.
Quick Start
# Using npx (recommended)
npx create-baf-app my-app
# Using npm create
npm create baf-app my-app
# Or install globally
npm install -g create-baf-app
create-baf-app my-appWhat's Included
This boilerplate comes with everything you need to build production-grade APIs:
- ⚡ Express 5 - Latest Express with async error handling
- 📘 TypeScript - Full type safety
- 🗄️ Prisma 7 - Type-safe ORM with PostgreSQL
- 🔐 Authentication - JWT, OTP, Google OAuth ready
- ✅ Zod Validation - Runtime type validation
- 🔌 Socket.IO - Real-time communication
- 📦 Redis - Caching & Socket.IO adapter
- 🔥 Firebase Admin - Push notifications
- 💳 Stripe - Payment integration
- ☁️ Cloudinary - Image uploads
- 🐳 Docker - Container ready
Project Structure
my-app/
├── prisma/
│ └── models/ # Prisma schema files
├── src/
│ ├── config/ # App configuration
│ ├── middlewares/ # Express middlewares
│ ├── modules/ # Feature modules
│ │ ├── auth/ # Authentication
│ │ ├── user/ # User management
│ │ └── upload/ # File uploads
│ ├── sockets/ # Socket.IO handlers
│ ├── utils/ # Helpers & utilities
│ └── app.ts # Entry point
├── docker-compose.yml
└── package.jsonCommands
npm run dev # Start development server
npm run start # Start production server
npm run g # Generate Prisma client
npm run m # Run database migrations
npm run build # Build for productionCLI Options
npx create-baf-app <project-name> [options]
Options:
--skip-install Skip npm install
--skip-git Skip git initialization
-V, --version Output version number
-h, --help Display helpRequirements
- Node.js 18+
- PostgreSQL (or use Docker)
- Redis (optional, for Socket.IO scaling)
Authors
- Bilal Ahmed - @baf-03
- Saif Ul llah - @Saif-Ul-llah
- Ayaan Mughal - @ayaan5210
License
MIT
