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 🙏

© 2025 – Pkg Stats / Ryan Hefner

create-xpress-server

v1.4.4

Published

CLI tool to scaffold Express.js servers with best practices, ESLint, TypeScript support, and more

Downloads

56

Readme

create-xpress-server: Your Express.js Project Scaffolding CLI

A powerful CLI tool designed to rapidly scaffold production-ready Node.js Express.js applications. 🚀 It streamlines project setup with customizable options for language (JavaScript/TypeScript), database (PostgreSQL/MongoDB), and essential services like email and Redis, ensuring best practices and a standardized structure from day one.

Features ✨

  • Interactive Project Generation: Guided prompts for project name, language, database, and additional services.
  • Language Support: Choose between JavaScript (.js) or TypeScript (.ts) for all generated source files.
  • Database Integration: Seamless setup for PostgreSQL (with Drizzle ORM) or MongoDB (with Mongoose ODM), or no database option.
  • Service Inclusion: Optionally integrate Nodemailer for email services and Redis for caching/rate-limiting.
  • Standardized Structure: Generates a well-organized src directory with dedicated folders for config, models, utils, controllers, middlewares, and routes.
  • Core Dependencies: Automatically includes essential packages like express, cors, morgan, jsonwebtoken, bcryptjs, helmet, dotenv, and more.
  • Configuration Best Practices: Sets up environment variables, JWT for authentication, a robust logging system, and a production-ready server boilerplate.
  • ES Modules First: All generated code adheres to ES module syntax, avoiding CommonJS require() statements.
  • Package Manager Auto-Detection: Intelligently suggests the package manager used to initiate the CLI.

Getting Started 🚀

Follow these steps to get create-xpress-server up and running on your local machine.

Installation

  1. Clone the Repository:

    git clone https://github.com/amnesia2k/create-xpress-server.git
    cd create-xpress-server
  2. Install Dependencies:

    npm install # or pnpm install or bun install
  3. Link the CLI (for local development/testing):

    npm link # or pnpm link or bun link

Using the Published CLI

For users looking to scaffold a new project, create-xpress-server can be used globally or via npx without prior installation:

Global Installation (Recommended for frequent use):

npm install -g create-xpress-server@latest
# or
pnpm install -g create-xpress-server@latest
# or
bun install -g create-xpress-server@latest

One-Time Usage:

npx create-xpress-server@latest
# or
pnpm dlx create-xpress-server@latest
# or
bunx create-xpress-server@latest

Usage 💡

Once installed globally, simply run the create-xpress-server command in your terminal from the directory where you want to create your new Express.js project.

create-xpress-server

The CLI will then guide you through a series of interactive prompts:

  1. Project Name: Enter the desired name for your new Express.js application. This will be the name of the directory created.
  2. Language Selection: Choose between JavaScript or TypeScript. All generated files will use the appropriate extension.
  3. Database Choice: Select your preferred database: PostgreSQL (with Drizzle ORM), MongoDB (with Mongoose ODM), or None if your project doesn't require a database.
  4. Services: Multi-select additional services to include:
    • Email: Integrates Nodemailer with basic configuration.
    • Redis: Sets up a Redis client for caching and rate-limiting.
  5. Package Manager: The CLI will auto-detect your current package manager (npm, pnpm, or bun) and suggest it, allowing you to confirm or choose another. This will be used for installing dependencies in your new project.

After your selections, the CLI will scaffold your new Express.js project with the chosen configurations and install all necessary dependencies.

Technologies Used 🛠️

| Category | Technology | Description | | :-------------------- | :------------------------------------------------------------ | :----------------------------------------------------- | | Core CLI | Node.js | JavaScript runtime for the CLI tool. | | | Commander.js | Node.js command-line interfaces. | | | Inquirer.js | Interactive command-line user interfaces. | | | Ora | Elegant terminal spinner. | | | Chalk | Terminal string styling. | | | Figlet.js | Creates ASCII art from text. | | | Gradient String | Colors strings with gradients. | | Generated Project | Express.js | Fast, unopinionated, minimalist web framework. | | (Core) | CORS | Middleware for enabling Cross-Origin Resource Sharing. | | | Morgan | HTTP request logger middleware. | | | JSON Web Token (JWT) | For secure authentication and authorization. | | | Cookie Parser | Parse Cookie header and populate req.cookies. | | | bcryptjs | Optimized bcrypt library for Node.js. | | | node-cron | A simple cron job scheduler. | | | Helmet | Security middleware for HTTP headers. | | | dotenv | Loads environment variables from a .env file. | | Generated Project | TypeScript | Strongly typed JavaScript (if selected). | | (Optional) | PostgreSQL | Powerful open-source relational database. | | | Drizzle ORM | TypeScript ORM for SQL databases. | | | Postgres.js | Fast, full-featured PostgreSQL client. | | | Drizzle Kit | Migrations and schema management for Drizzle. | | | MongoDB | NoSQL, document-oriented database. | | | Mongoose | MongoDB object data modeling (ODM). | | | Nodemailer | Send e-mails with Node.js. | | | Redis | Open source, in-memory data structure store. |

Contributing 🤝

We welcome contributions to create-xpress-server! If you have suggestions for improvements, new features, or bug fixes, please follow these guidelines:

  • Fork the repository.
  • Create a new branch for your feature or bug fix: git checkout -b feature/your-feature-name.
  • Make your changes, ensuring they adhere to the project's code style.
  • Test your changes thoroughly to prevent regressions.
  • Commit your changes with clear and concise messages.
  • Push your branch to your forked repository.
  • Open a Pull Request against the main branch of this repository, describing your changes in detail.

License 📄

This project is licensed under the MIT License.

Author Information 🧑‍💻

Olatilewa Olatoye


NPM Version License: MIT Node.js Version Built With Node.js

Readme was generated by Dokugen