What's New in v2.0.0
v2.0.0 is a major release that adds TypeScript support and significantly expands the generated project structure. Here's what changed:
- TypeScript and JavaScript templates
- Redis caching layer with type-safe implementation
- Structured logging via Pino (correlation IDs, JSON output)
- Health check endpoints (Kubernetes liveness/readiness probes)
- Database seeders
- Docker multi-stage builds (~100MB images)
- GitHub Actions CI/CD pipeline
- Pre-commit hooks using Husky + lint-staged
- Swagger/OpenAPI documentation
- Graceful shutdown handling
- Project-level docs: SKILLS.md, SEEDERS.md, CONTRIBUTING.md
Full Changelog
Overview
TryAppStack is a CLI that generates Node.js project boilerplates with a well-defined folder structure, pre-configured dependencies, and sensible defaults.
Instead of spending time wiring up auth, logging, Docker, linting, and CI/CD from scratch, you run one command and get a working project that's ready to build on.
Learn more
Quick Start
Installation
Install globally:
npm install -g tryappstack
Or use npx without installing:
npx tryappstack init
Create a Project
tas init
cd my-project
npm run dev
What Gets Generated
After tas init, your project includes:
- A complete folder structure following standard conventions
- All dependencies installed
- Environment variables configured (.env)
- An initialized Git repository
- Docker and Docker Compose setup
- A CI/CD pipeline (GitHub Actions)
- Project documentation
Common Next Steps
npm run db:seed
tas add-module Product
npm run docker:run
Features
Authentication and Security
- JWT-based authentication
- OTP verification (email/phone)
- Password reset flow
- Role-based access control (RBAC)
- Helmet security headers
- Rate limiting
- XSS protection
- MongoDB query sanitization
Logging and Monitoring
- Structured JSON logging with Pino
- Correlation IDs for request tracing
- Request/response logging
- Error tracking
- Health check endpoints:
/health, /health/liveness, /health/readiness
Performance
- Redis caching layer
- Response compression
- Connection pooling
- Small Docker images (~100MB)
DevOps
- Multi-stage Docker builds
- Docker Compose for local orchestration
- GitHub Actions CI/CD
- Pre-commit hooks (Husky + lint-staged)
- Conventional commits via commitlint
- Container health checks
Documentation (Auto-Generated)
- Swagger/OpenAPI docs
- Architecture overview
- TypeScript guide (TS template only)
- Database seeding guide
- Contributing guidelines
- Coding standards (SKILLS.md)
Database
- Mongoose ODM with TypeScript support
- Seeders for bootstrapping data
- Migration-ready structure
- Indexed schemas
Developer Experience
- Hot reload via nodemon
- ESLint + Prettier pre-configured
- Path aliases for TypeScript (
@/)
- Auto-formatting on commit
- Type-safe environment variables
- Centralized error handling
CLI Commands
Project Setup
tas init | i | Create a new project (interactive) |
tas --version | -v | Show CLI version |
tas --help | -h | Show help |
Code Generation
These commands detect whether your project uses TypeScript or JavaScript and generate the right files accordingly.
tas add-module <name> | mod | Generate controller + model + router |
tas add-controller <name> | c | Generate a controller |
tas add-model <name> | m | Generate a Mongoose model |
tas add-router <name> | r | Generate an Express router |
tas add-service <name> | s | Generate a service |
tas add-middleware <name> | mid | Generate middleware |
tas add-utils <name> | u | Generate a utility module |
tas add-templates <name> | tpl | Generate an HTML template |
Environment Management
tas setup-env | env | Set up environment variables |
tas add-var-env <name> | addenv | Add a new env variable |
Note: All add-* commands must be run inside a project created with tas init.
Template Detection
The CLI figures out which template your project uses and generates code accordingly:
tas add-router Product
tas add-router Product
Available Templates
Node.js + MongoDB + Express (JavaScript)
A complete JavaScript API project with JWT auth, OTP verification, Pino logging, Redis caching, Docker + Compose, GitHub Actions CI/CD, Swagger docs, database seeders, pre-commit hooks, and project documentation.
Node.js + MongoDB + Express (TypeScript)
Everything from the JavaScript template, plus: TypeScript with generics and utility types, DTOs using class-validator, path aliases (@/), type-safe environment validation, a TypeScript best practices guide, and architecture documentation.
Planned
- Node API with PostgreSQL + TypeORM
- Node API with MySQL + TypeORM
- GraphQL API
- React SPA
- Next.js Fullstack
- Microservices architecture
Deployment
Docker
npm run docker:build
npm run docker:run
Cloud
Both templates are configured for deployment to AWS (EC2, ECS, Fargate), Google Cloud (Cloud Run, GKE), Azure (ACI, AKS), DigitalOcean, Heroku, Railway, and Render.
Kubernetes-specific setup is included: health check endpoints, graceful shutdown, non-root Docker user, and small image sizes.
See the template-specific READMEs for deployment details.
Documentation
Each generated project includes:
- README.md — Setup and usage
- SKILLS.md — Coding standards and conventions
- SEEDERS.md — Database seeding guide
- CONTRIBUTING.md — Development workflow
- ARCHITECTURE.md — System design overview (TypeScript only)
- TYPESCRIPT_GUIDE.md — TypeScript patterns and practices (TypeScript only)
Contributing
Contributions are welcome. See CONTRIBUTING.md for guidelines on submitting changes, adding templates, and improving CLI commands.
Roadmap
v2.x (Current)
- TypeScript and JavaScript templates
- Redis caching
- Docker and CI/CD
- Database seeders
- Template-aware code generation
v3.0
- PostgreSQL + TypeORM template
- MySQL + TypeORM template
- GraphQL API template
- Microservices architecture
- WebSocket support
- Message queue integration (RabbitMQ/Kafka)
- Elasticsearch integration
- Multi-tenancy support
v4.0
- Next.js fullstack template
- React SPA template
- React Native template
- Electron desktop template
- Serverless templates (AWS Lambda, Vercel)
Links
Acknowledgments
Project structure and conventions are influenced by patterns used at Vercel, Linear, GitHub, and Google.
License
MIT — Dushyant Khoda
See LICENSE for details.