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

@mlbstack/create

v0.2.0

Published

Official MLB Stack project scaffolder. Creates a project aligned with the MLB golden path: Next.js or Vite + TypeScript + Tailwind CSS + shadcn/ui + ESLint.

Downloads

76

Readme

@mlbstack/create

Official MLB project scaffolder. It creates a project aligned with the MLB golden path so a new developer does not have to research how to configure Next.js, Tailwind CSS, shadcn/ui or ESLint.

npm create @mlbstack@latest

You choose a framework (Next.js or Vite) and receive a project that already uses the technologies the MLB standardizes on.

Stack

The official templates always include:

  • TypeScript
  • Tailwind CSS
  • shadcn/ui
  • ESLint

The CLI never asks about these — they are part of the golden path and reduce the number of decisions a developer has to make.

Uso

npm create @mlbstack@latest

You can also run it with npx:

npx @mlbstack/create@latest

Exemplos

npm create @mlbstack@latest my-app

npm create @mlbstack@latest my-app -- --template next

npm create @mlbstack@latest my-app -- --template vite

npm create @mlbstack@latest my-app -- --template next --package-manager pnpm

npm create @mlbstack@latest my-app -- --template next --no-install

npm create @mlbstack@latest my-app -- --template vite --skip-git

npm create @mlbstack@latest my-app -- --yes

Templates

| id | name | stack | | ------ | ----------------- | ---------------------------------------------------------------- | | next | MLB Stack Next.js | Next.js + React + TypeScript + Tailwind CSS + shadcn/ui + ESLint | | vite | MLB Stack Vite | Vite + React + TypeScript + Tailwind CSS + shadcn/ui + ESLint |

CLI options

| Option | Description | Default | | ------------------- | ---------------------------------------- | ----------- | | [project-name] | Name of the project to create. | prompted | | -t, --template | Template to use (next, vite). | prompted | | --framework | Framework to use (next, vite). | inferred | | --package-manager | Package manager (npm, pnpm, yarn). | detected | | --no-install | Skip installing dependencies. | install | | --skip-git | Skip initializing a Git repository. | git init | | -y, --yes | Use defaults without prompting. | interactive | | -v, --version | Print the CLI version. | — | | -h, --help | Show help. | — |

--yes defaults

When --yes is used, the CLI does not prompt and applies these defaults:

  • Project name: the [project-name] argument, or my-app.
  • Framework: the --template/--framework flag, or next.
  • Package manager: the --package-manager flag, or detected from lockfiles, otherwise npm.
  • Install dependencies: yes (disable with --no-install).
  • Initialize Git: yes (disable with --skip-git).

Filesystem safety

The CLI validates the project name, resolves an absolute path and checks the target directory before generating. It never silently overwrites existing files.

  • If the directory is missing or empty, generation proceeds.
  • If the directory is not empty, the CLI fails safely in non-interactive mode: Directory "my-app" is not empty.
  • In interactive mode it asks for confirmation before continuing.

Desenvolvimento

Clone the repository and install dependencies:

npm install
npm run build
npm test
npm run lint
npm run typecheck

| Command | Description | | ---------------------- | ---------------------------------- | | npm run build | Build the CLI into dist/. | | npm run typecheck | Run TypeScript type checking. | | npm run lint | Run ESLint. | | npm test | Run the Vitest test suite. | | npm run test:watch | Run tests in watch mode. | | npm run format | Format the codebase with Prettier. | | npm run format:check | Check formatting with Prettier. |

Testing templates locally

Structure checks run for every template in the regular test suite. To run a full smoke test that installs dependencies and builds a generated project (requires network access and more time):

MLB_SMOKE=1 npm test

Adicionando templates

  1. Create a directory under templates/ (e.g. templates/expo).
  2. Register it in src/templates/registry.ts with an id, name, framework, description, path and stack.
  3. Create a generator wrapper under src/generators/ and register it in src/generators/index.ts.

Because the registry drives template discovery, there is no scattered list of template ids to maintain.

Publicação

Bump the version in package.json, then publish:

npm publish

The package ships dist/ and templates/ only (see the files field). Set the publishConfig.access to public for an unscoped-visible scoped package (already configured).

Architecture

src/
├── cli.ts                 entrypoint (shebang, commander wiring)
├── commands/create.ts     create flow orchestration
├── prompts/               interactive prompts
├── generators/            per-framework generators (next, vite)
├── templates/registry.ts  central template registry
├── core/                  template model, generator, package manager, git
└── utils/                 validation, filesystem, logger, errors
templates/                 template directories (next, vite)
tests/                     unit + smoke tests

The design intentionally separates the CLI from prompts, the registry, generators, filesystem and package managers so future templates (expo, nest, library, ...) and shared @mlbstack/* configuration packages can be added without restructuring the project.

License

MIT