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

@incoderashu/create-express-app

v1.1.0

Published

Scaffold production-ready Express.js backends with security, validation, and best practices baked in.

Readme

create-express-app

Scaffold production-ready Express.js backends with security, database options, testing, API documentation, Docker support, and best practices baked in.

Quick Start

npx @incoderashu/create-express-app my-api
cd my-api
npm run dev

Or install globally:

npm install -g @incoderashu/create-express-app
create-express-app my-api

Interactive Experience

$ npx @incoderashu/create-express-app my-api

        ⚡ Create Express App

◇ Choose your language
│ ❯ TypeScript
│   JavaScript

◇ Choose module system
│ ❯ ESM
│   CommonJS

◇ Choose database
│ ❯ PostgreSQL + Prisma
│   MongoDB + Mongoose
│   None

◇ Select features
│ ◉ Security
│ ◉ Validation
│ ◉ Testing
│ ◉ ESLint + Prettier
│ ◯ Swagger / OpenAPI
│ ◯ Docker
│ ◯ CRUD example

┌─ Configuration ──────────────────────────┐
│ TypeScript • ESM • PostgreSQL + Prisma   │
│ Security • Validation • Testing          │
│ ESLint + Prettier                        │
└──────────────────────────────────────────┘

◇ Create project?
│ ❯ Yes

✔ Project structure created
✔ Configuration generated
✔ Features configured
✔ Dependencies installed

✨ Done!

  cd my-api
  npm run dev

  http://localhost:5000

CLI Flags

Skip any prompt with flags for automated CI or non-interactive use:

| Flag | Description | Default | | -------------------- | ------------------------------------------------------------ | --------------------- | | --js | Use JavaScript | true | | --ts | Use TypeScript | false | | --cjs | Use CommonJS module system | true | | --esm | Use ESM module system | false | | --db <choice> | Database: none, mongo, postgres | mongo | | --nodemon | Install nodemon for auto-reload | true | | --no-nodemon | Skip nodemon | false | | --tests | Add testing setup (Vitest + Supertest) | true (with --yes) | | --no-tests | Skip testing setup | false | | --docs <choice> | API documentation: none, swagger | none | | --docker | Add Dockerfile and docker-compose.yml setup | false | | --auth | Add JWT authentication (requires MongoDB or PostgreSQL) | false | | --extras <list> | Comma-separated extras: security,validator,eslint-prettier,crud-sample,docker,auth | None | | --all-extras | Enable all applicable extras | false | | --install | Install dependencies after scaffolding | true | | --no-install | Skip dependency installation | false | | --yes, -y | Accept sensible defaults (JS, CJS, Mongo, nodemon, tests, security, install) | false | | --help, -h | Show help message | | | --version, -v | Show version number | |

Examples

# All defaults — JS, CJS, MongoDB, nodemon, testing, security
create-express-app my-api --yes

# TypeScript + ESM + PostgreSQL + Prisma + Auth + Swagger + Testing + Docker
create-express-app my-api --ts --esm --db=postgres --auth --docs=swagger --tests --docker --yes

# Minimal API without database or tests (CI usage)
create-express-app my-api --js --cjs --db=none --no-tests --no-install

# Custom extras with CommonJS, MongoDB, and Auth
create-express-app my-api --js --cjs --db=mongo --auth --extras validator,security,docker --no-install

Generated Project Structure

my-api/
├── src/
│   ├── config/
│   │   ├── db.js             # MongoDB connection or Prisma client singleton
│   │   └── swagger.js        # Swagger / OpenAPI spec (if docs enabled)
│   ├── controllers/
│   │   ├── health.controller.js
│   │   ├── items.controller.js # CRUD sample controller (if selected)
│   │   └── auth.controller.js  # JWT Auth controller (if auth selected)
│   ├── middlewares/
│   │   ├── errorHandler.js   # Centralized error handler
│   │   ├── notFound.js       # 404 catch-all
│   │   ├── security.js       # Helmet, rate-limit, HPP (if security selected)
│   │   └── auth.middleware.js# protect and authorize guards (if auth selected)
│   ├── models/               # Mongoose models (user.model.js, item.model.js)
│   ├── routes/
│   │   ├── index.js          # Route aggregator
│   │   ├── health.routes.js  # Health check route (with OpenAPI annotations)
│   │   ├── items.routes.js   # CRUD sample routes (if selected)
│   │   └── auth.routes.js    # Auth routes (/register, /login, /refresh, etc.)
│   ├── utils/
│   │   ├── asyncHandler.js   # try/catch async wrapper
│   │   ├── token.js          # JWT signing, verification, and SHA-256 hash
│   │   └── cookie-options.js # Centralized httpOnly cookie options
│   ├── app.js                # Express app configuration & middleware
│   └── server.js             # HTTP server entry point & DB bootstrap
├── prisma/
│   └── schema.prisma         # Prisma schema (User, RefreshToken, Item models)
├── tests/
│   ├── health.test.js        # Supertest route tests (if testing enabled)
│   ├── auth.test.js          # Auth endpoints & token reuse tests (if auth + tests)
│   └── setup.js              # Test environment & DB lifecycle hooks
├── Dockerfile                # Multi-stage or production container build (if Docker selected)
├── .dockerignore
├── docker-compose.yml        # Docker compose service definition (if Docker selected)
├── .env
├── .env.example
├── .gitignore
├── package.json
├── vitest.config.js          # Test runner config (if testing enabled)
├── tsconfig.json             # TypeScript config (if TS selected)
└── README.md

Available Scripts (generated project)

| Script | Description | | ---------------------- | --------------------------------------------------- | | npm run dev | Start development server (with auto-reload) | | npm start | Start production server | | npm test | Run test suite with Vitest (if testing enabled) | | npm run test:watch | Run tests in interactive watch mode | | npm run test:coverage| Generate test coverage report | | npm run build | Compile TypeScript with tsc (TS only) | | npm run docker:up | Build and start Docker containers (if Docker extra) | | npm run docker:down | Stop Docker containers (if Docker extra) | | npm run lint | Run ESLint (if ESLint extra selected) | | npm run format | Run Prettier formatting (if extra selected) |

License

MIT