npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@sachin-thakur/create-nodejs-app

v1.0.0

Published

A CLI tool to scaffold production-ready Node.js applications with best practices

Readme

Create Production Node App

🚀 A powerful CLI tool to scaffold production-ready Node.js applications with modern best practices, complete with TypeScript support, database integration, authentication, testing, and more.

✨ Features

Unlike other scaffolding tools that give you a basic "Hello World" template, Create Production App generates applications that are ready for production deployment with:

  • 🎯 Multiple Project Types: REST API, GraphQL API, Microservices, CLI Tools
  • 📐 Architecture Patterns: MVC, Clean Architecture, Feature-based (Modular)
  • 💎 TypeScript or JavaScript: Full TypeScript support with strict mode
  • 🗄️ Database Integration: PostgreSQL, MongoDB, MySQL with connection pooling
  • 🔐 Authentication: JWT-based auth with bcrypt password hashing
  • Request Validation: Input validation with Zod
  • 📝 Logging: Structured logging with Winston
  • 📚 API Documentation: Auto-generated Swagger/OpenAPI docs
  • 🛡️ Security: Rate limiting, CORS, helmet, input sanitization
  • Caching: Redis integration for performance
  • 📧 Email Service: Nodemailer setup for transactional emails
  • 📁 File Upload: Multer configuration for file handling
  • 🔄 Background Jobs: Bull queue for async task processing
  • 🧪 Testing: Jest, Vitest, or Mocha with example tests
  • 🐳 Docker: Complete Docker and docker-compose setup
  • 🔄 CI/CD: GitHub Actions workflow configured
  • 📦 ESLint & Prettier: Code quality and formatting

🚀 Quick Start

Using npx (Recommended)

npx create-nodejs-app my-awesome-app

Using npm

npm install -g create-nodejs-app
create-nodejs-app my-awesome-app

Using yarn

yarn global add create-nodejs-app
create-nodejs-app my-awesome-app

📖 Usage

Simply run the command and follow the interactive prompts:

npx create-nodejs-app my-app

You'll be asked to choose:

  1. Project Type: REST API, GraphQL API, Microservice, or CLI Tool
  2. Language: TypeScript (recommended) or JavaScript
  3. Architecture: MVC, Clean Architecture, or Feature-based
  4. Database: PostgreSQL, MongoDB, MySQL, or None
  5. Features:
    • Authentication (JWT)
    • API Documentation (Swagger)
    • Request Validation
    • Error Handling & Logging
    • Rate Limiting
    • CORS Configuration
    • File Upload
    • Email Service
    • Caching (Redis)
    • Background Jobs
  6. Testing Framework: Jest, Vitest, Mocha, or None
  7. Docker: Include Docker configuration
  8. CI/CD: Include GitHub Actions workflow

📦 What You Get

After running the CLI, you'll have a fully structured project:

my-app/
├── src/
│   ├── config/          # Configuration files
│   │   ├── database.ts  # Database connection
│   │   ├── logger.ts    # Winston logger setup
│   │   └── swagger.ts   # Swagger configuration
│   ├── controllers/     # Request handlers
│   ├── models/          # Database models
│   ├── routes/          # API routes with Swagger docs
│   ├── middlewares/     # Custom middlewares (auth, validation, error handling)
│   ├── services/        # Business logic layer
│   ├── utils/           # Utility functions
│   └── index.ts         # Application entry point
├── tests/               # Test files
├── .github/
│   └── workflows/       # CI/CD configuration
├── Dockerfile           # Docker configuration
├── docker-compose.yml   # Multi-container setup
├── .env.example         # Environment variables template
├── .gitignore
├── .eslintrc.json       # ESLint configuration
├── .prettierrc          # Prettier configuration
├── tsconfig.json        # TypeScript configuration (if TS)
├── package.json
└── README.md            # Project-specific README

🎯 Example Projects

REST API with PostgreSQL

npx create-nodejs-app my-api
# Select: REST API, TypeScript, MVC, PostgreSQL
# Select features: Auth, Validation, Logging, Swagger, Rate Limiting, CORS
# Select: Jest, Docker, CI/CD

This generates a production-ready REST API with:

  • JWT authentication
  • PostgreSQL database with connection pooling
  • Request validation with Zod
  • Comprehensive error handling
  • Swagger API documentation
  • Rate limiting and CORS
  • Docker setup with PostgreSQL container
  • CI/CD pipeline with GitHub Actions

Microservice with MongoDB

npx create-nodejs-app user-service
# Select: Microservice, TypeScript, Clean Architecture, MongoDB
# Select features: Auth, Validation, Logging, Caching, Background Jobs
# Select: Jest, Docker, CI/CD

🔧 Development

After creating your project:

cd my-app
npm install
cp .env.example .env
# Edit .env with your configuration
npm run dev

Your app will be running at http://localhost:3000

If you included Swagger, visit: http://localhost:3000/api-docs

🐳 Using Docker

If you included Docker configuration:

docker-compose up

This will start your application along with the database and any other services (Redis, etc.)

🧪 Testing

npm test                 # Run tests
npm run test:watch       # Watch mode
npm run test:coverage    # Coverage report

🏗️ Architecture Patterns

MVC (Model-View-Controller)

Traditional and straightforward. Great for most REST APIs and web applications.

Clean Architecture (Layered)

Domain-driven with clear separation of concerns. Ideal for complex business logic and enterprise applications.

Feature-based (Modular)

Organized by features rather than technical layers. Perfect for microservices and scalable applications.

🤔 Why Create Production App?

Most Node.js scaffolding tools give you a basic structure, but lack:

  • ❌ Proper error handling patterns
  • ❌ Logging configuration
  • ❌ Security best practices
  • ❌ Database setup with migrations
  • ❌ Authentication implementation
  • ❌ API documentation
  • ❌ Testing examples
  • ❌ Docker and CI/CD setup

Create Production App provides all of this out of the box, so you can focus on building features instead of boilerplate.

📚 Documentation

For more detailed information, check out:

🤝 Contributing

Contributions are welcome! Please read our Contributing Guide for details.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📝 License

MIT License - see LICENSE file for details

🙏 Acknowledgments

Built with ❤️ to help developers ship production-ready applications faster.

🐛 Issues

Found a bug or have a feature request? Please open an issue on GitHub.

⭐ Star Us!

If you find this tool helpful, please consider giving it a star on GitHub!


Happy coding! 🚀