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

@michaellhobart/napkin

v0.1.0

Published

Turn your architecture diagrams into runnable sketches using Docker Compose

Downloads

90

Readme

Napkin

Turn your architecture diagrams into runnable sketches.

Architecture reviews often produce diagrams that describe systems as discrete components (web app, API, workers, queues, DB, external deps). However, validating those designs usually requires scaffolding a real system—which is slow and distracts from the design intent.

Napkin is a CLI + generator that turns architecture primitives into low-fidelity, runnable surfaces using Docker Compose. It allows teams to quickly test assumptions about integration boundaries, data flow, failure modes, and deployment topology.

Key Features

  • Runnable Sketches: Generate minimal, functional components (UI, API, Store, Worker) from a simple manifest.
  • Composition First: Wire nodes together based on edges in the manifest, producing a runnable system via Docker Compose.
  • Low Fidelity, High Value: Focus on surfaces and contracts, not production implementations. Validate sync vs async interactions and failure modes early.
  • Fault Injection: Built-in support for latency and error rate simulation to test system resilience.
  • Docker Compose Glue: Leverages Docker Compose for consistent networking, startup, and environment management.

Getting Started

Prerequisites

Installation

Install the CLI globally via npm:

npm install -g @michaellhobart/napkin

Development Setup

If you want to contribute or build from source:

git clone https://github.com/michaellhobart/napkin.git
cd napkin
npm install
npm run build
npm link

Usage

  1. Initialize a new project:

    napkin init

    This creates a napkin.yaml file in your current directory, which serves as the source of truth for your architecture sketch.

  2. Generate a REST service:

    # Generate a simple service
    napkin generate service users
       
    # Generate a service with a specific schema
    napkin generate service books --schema "title, author, year"

    This scaffolds a lean REST API in services/<name>/ using only native Node.js modules. It includes an in-memory CSV storage provider for quick prototyping.

  3. Start a service:

    cd services/books
    npm start
  4. Wired up (Docker Compose): Coming Soon: Generate the docker-compose.yaml from your manifest.

Documentation

For more detailed information on the project structure and design, see docs/ARCHITECTURE.md.

Design Principles

  1. Low Fidelity: Runnable artifacts with one command, explicit surfaces (HTTP/NATS), and minimal behavior.
  2. Avoid Combinatorial Explosion: Support "blessed stacks" for each primitive (e.g., Fastify for APIs, Vite for UIs).
  3. Manifest-First: The napkin.yaml is the source of truth for the entire system architecture.

License

MIT

Distribution

This package is published to the npm registry under the @michaellhobart scope.

Publishing

To publish a new version:

  1. Update the version in package.json.
  2. Push a new tag: git tag v0.x.x && git push origin v0.x.x.
  3. The GitHub Action will automatically build and publish the package to npm.