create-stackflow
v1.0.18
Published
Interactive CLI for generating modern full-stack MERN applications.
Maintainers
Readme
create-stackflow
Professional interactive npm CLI for generating modern full-stack MERN and modern web applications.
npx create-stackflowOverview
create-stackflow is a modern developer-focused CLI tool that automatically generates scalable full-stack applications with production-ready architecture.
The goal of StackFlow is to reduce repetitive setup time and instantly generate:
- Frontend
- Backend
- Authentication
- CRUD modules
- Dashboard UI
- API setup
- Database connection
- Protected routes
- Upload system
- Validation
- Modern folder structure
Everything is generated automatically with interactive prompts.
Perfect For
create-stackflow is ideal for:
- MERN Stack developers
- Full-stack developers
- SaaS starters
- Admin dashboard projects
- Startup MVPs
- CRUD applications
- Authentication systems
- Portfolio projects
- Client projects
- Rapid prototyping
- Agency development workflows
What StackFlow Generates
Frontend
Supports:
- React + Vite
- Next.js
Features:
- JavaScript or TypeScript
- Tailwind CSS
- Shadcn UI
- React Router DOM
- Zustand / Redux Toolkit / Context API
- React Hook Form
- Zod / Yup validation (Joi is backend-only)
- Axios API layer
- TanStack Query
- Protected routes
- Dark mode
- Toast notifications
- Framer Motion
- Charts
- Drag & drop uploads
Backend
Supports:
- Express.js
- Fastify
- NestJS
Features:
- MongoDB
- PostgreSQL
- MySQL
- SQLite
- Mongoose / Prisma / Sequelize / Drizzle / TypeORM
- JWT Authentication
- bcryptjs / argon2
- multer
- Cloudinary
- Cloudflare R2
- AWS S3
- UploadThing
- Swagger Docs
- Socket.IO
- Winston / Morgan / Pino logging
- Nodemailer
- AWS SES
- SendGrid
- Mailgun
- Postmark
Generated Features
StackFlow automatically generates:
- Login page
- Register page
- Forgot password
- Reset password
- Role-based authentication
- Refresh token support
- Dashboard UI
- CRUD APIs
- CRUD frontend pages
- API service layer
- Validation structure
- Auth middleware
- Upload structure
- Environment variables
- MongoDB connection
- Loading states
- Toast notifications
- Reusable component architecture
Generated Project Structure
my-app/
│
├── frontend/
│ └── package.json
│
├── backend/
│ └── package.json
│
└── node_modules/ (hoisted at project root after install)Backend API Architecture
StackFlow uses a scalable modular API architecture.
Main Route File
Example:
router.use("/auth", authRoutes);
router.use("/users", userRoutes);
router.use("/products", productRoutes);The main route file combines all module routes.
Separate Module Routes
Each module contains its own dedicated route file.
Example:
router.get("/");
router.post("/");
router.put("/:id");
router.delete("/:id");This keeps the codebase:
- clean
- scalable
- maintainable
- enterprise-ready
Interactive Setup Questions
StackFlow asks setup questions like:
? Frontend framework?
❯ React
Next.js
? Language?
❯ TypeScript
JavaScript
? Database?
❯ MongoDB
PostgreSQL
? Authentication strategy?
❯ JWT
Session AuthEverything is configured automatically based on user selections.
Local Development Workflow
Create Project
npx create-stackflowStart Project
Start Backend
cd my-app/backend
npm run devStart Frontend
cd my-app/frontend
npm run devLocal MongoDB
Default MongoDB connection:
MONGO_URI=mongodb://127.0.0.1:27017/myappCLI Architecture
src/
│
├── cli.js
│
├── commands/
│
├── generators/
│
├── templates/
│
├── prompts/
│
├── utils/
│
└── constants/StackFlow Workflow
- Ask setup questions
- Validate project name
- Create frontend
- Create backend
- Install dependencies
- Configure Tailwind
- Configure Shadcn
- Configure backend
- Configure database
- Generate auth
- Generate CRUD
- Configure routes
- Generate dashboard
- Create env files
- Start project automatically
Dependency Strategy
StackFlow uses latest stable versions automatically.
Examples:
vite@latestcreate-next-app@latest
Dependencies are dynamically installed based on selected features.
Auth Strategy
Generated authentication system includes:
- JWT authentication
- Password hashing
- Protected APIs
- Protected frontend routes
- HTTP-only cookies
- Refresh tokens
- Role-based access
CRUD Strategy
StackFlow automatically generates:
Backend
- Models
- Controllers
- Routes
- Middleware
- Validation
Frontend
- Forms
- Tables
- Dashboard pages
- API services
- Loading states
Why StackFlow?
StackFlow helps developers:
- save setup time
- avoid repetitive boilerplate
- follow scalable architecture
- build production-ready projects faster
- maintain consistent code structure
Recommended Stack
Frontend
- React / Next.js
- Tailwind CSS
- Shadcn UI
- Zustand
- Axios
- React Hook Form
- Zod
Backend
- Express.js
- MongoDB
- Mongoose
- JWT
- bcryptjs
- multer
- Cloudinary
Future Roadmap
Planned future support:
- SaaS starters
- AI application starters
- React Native
- Prisma
- PostgreSQL
- Redis
- BullMQ
- Docker
- Admin generators
- Visual generators
Local Testing
npm run smoke
node ./src/cli.jsPublishing
npm publish --access publicInstall Globally
npx create-stackflowLicense
MIT
Author
StackFlow CLI
