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

@mockkit/cli

v0.0.6

Published

`@mockkit/cli` helps you initialize mockups, wireframes, or frontend apps built with static site generators (SSG) as MockKit projects, preview them in a development environment, and publish them to [MockKit](https://mockkit.app).

Readme

@mockkit/cli

@mockkit/cli helps you initialize mockups, wireframes, or frontend apps built with static site generators (SSG) as MockKit projects, preview them in a development environment, and publish them to MockKit.

Geting Started

cd /path/to/your/existing/mockup/site
npx @mockkit/cli --help
npx @mockkit/cli init
npx @mockkit/cli generate
npx @mockkit/cli publish

Commands

  • mockkit init [projectDir]: Create or overwrite mockkit.json with interactive prompts.
  • mockkit configure [--clear]: Save or clear your MockKit API Key.
  • mockkit publish [projectDir] [--site-id <id>] [--dist-path <path>]: Upload static build artifacts.
  • mockkit dev [projectDir]: Run the dev command defined in mockkit.json.
  • mockkit generate [projectDir]: Run the static generation command defined in mockkit.json.
  • mockkit manifest [projectDir]: Sync mockkit-manifest.json from mockkit.json.

Prerequisites

  • Node.js (current LTS is recommended).
  • A static site project directory where you run the command.
  • For publish: a valid MockKit API Key.

Installation and execution

This package exposes the mockkit binary.

You can run it with the following command even without installing it first.

npx @mockkit/cli

If it is already installed in your project's package.json:

npm exec mockkit

Or, if mockkit is installed globally:

mockkit

Quick start

  1. Initialize MockKit in your existing project (such as one built with Nuxt, 11ty, or another static site generator):
cd /path/to/project
mockkit init
  1. Configure your API Key:
mockkit configure
  1. Build your static site so files exist under your output directory (for example ./dist).
mockkit generate
  1. Publish artifacts:
mockkit publish

init

init creates mockkit.json in the target directory.

If not specified, projectDir defaults to the current directory.

mockkit init [projectDir]

Prompt flow

init asks for:

  • Project name
  • Static site generator (currently you can choose either manual or nuxt)
  • Destination directory (build.distDir)
  • Public directory (build.publicDir)
  • Development server port (build.devPort)
  • Development command (build.devCommand)
  • Static generation command (build.generateCommand)

If mockkit.json already exists, the CLI asks for overwrite confirmation first.

Nuxt detection behavior

When nuxt is selected, the CLI detects defaults from one of:

  • nuxt.config.ts
  • nuxt.config.js
  • nuxt.config.mjs
  • nuxt.config.cjs

If none is found, init aborts.

configure

configure stores your API Key in:

  • ~/.mockkit/credentials.json

Run:

mockkit configure

To remove the saved key:

mockkit configure --clear

publish

publish uploads files from your built output directory to MockKit.

mockkit publish [projectDir] [options]

Options

  • --site-id <id>: Use this site ID directly.
  • --dist-path <path>: Build artifact directory.

Requirements

  • mockkit.json must exist in projectDir.
  • dist-path must exist and be a directory.
  • At least one file must exist under dist-path.

Site ID resolution order

When --site-id is not provided, the CLI resolves site ID in this order:

  1. siteId in mockkit.json
  2. Interactive selection from API site list
  3. Interactive creation of a new site

After resolution, the selected site ID is written back to mockkit.json.

dev

dev starts the development workflow and keeps mockkit-manifest.json in sync.

mockkit dev [projectDir]

Behavior:

  • Runs build.devCommand from mockkit.json.
  • Starts the MockKit Viewer development server.
  • Watches mockkit.json, and when it changes, rewrites mockkit-manifest.json in the configured build.publicDir.

generate

generate runs build.generateCommand from mockkit.json in projectDir.

mockkit generate [projectDir]

If not specified, projectDir defaults to the current directory.

Before running the generation command, generate rewrites mockkit-manifest.json in the configured build.publicDir.

manifest

manifest syncs mockkit-manifest.json from mockkit.json.

mockkit manifest [projectDir]

If not specified, projectDir defaults to the current directory.

Troubleshooting

  • mockkit.json does not exist...
    • Run mockkit init in the correct project directory.
  • Dist path does not exist... or is not a directory...
    • Make sure to build your project as a static site first (for example, by running nuxt generate).
  • No files found under dist path...
    • Confirm your static build output is generated and not empty.
  • API Key is required to run publish...
    • Run mockkit configure and set a key starting with mk_apikey_.
  • API request failure messages (4xx/5xx)
    • Verify API Key validity and site access permissions.