feat: added Next.js + Express + MongoDB Template #100
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🚀 Add Next.js + Express + MongoDB Template
Overview
This PR adds a Next.js + Express + MongoDB starter template to Celtrix, providing developers with a modern full-stack solution that bridges a Next.js frontend with a dedicated Express backend and MongoDB integration. Available in both TypeScript and JavaScript variants.
✨ Key Features
Frontend (Next.js 15)
App Router with latest Next.js features
TailwindCSS for responsive, modern styling
Mobile-first design
ESLint & Prettier configuration
Sample components: User management interface
API integration examples
Custom 404 page
Backend (Express.js)
Express 5 with modern middleware
MongoDB/Mongoose integration
Security with Helmet and CORS
Request logging with Morgan
Full CRUD API for user management
MVC architecture
Health check endpoints
📊 API Endpoints
🔧 CLI Integration & Setup
Added Next.js + Express + MongoDB option to CLI selection menu
Template manager updated for new stack structure
Setup commands:
🎯 Why This Matters
Separation of concerns: Frontend and backend scalable independently
Modern stack: Latest Next.js 15 + Express 5
Production ready: Security, validation, and error handling built-in
Developer friendly: TypeScript-first with comprehensive documentation
🧪 Testing
Verified all package versions install correctly
Template copying works for TS and JS
Frontend builds and runs
Backend starts and connects to MongoDB
API endpoints function correctly
404 page displays properly
CLI integration works seamlessly
Impact:
Adds a modern full-stack alternative to MERN with better separation of concerns, flexible backend scaling, Express ecosystem compatibility, and TypeScript-first development experience.
Closes: [Link to related issue]
Demo: Available via
npx celtrix→ select new stack option