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

create-dokio

v0.1.28

Published

CLI scaffold for Dokio templates

Readme

create-dokio

CLI scaffold for Dokio hub repos and templates. Generates correct file structure, data.yaml, HTML boilerplate, SCSS partials, and auto-wires changelog tooling.


Getting started

Run from your repos workspace folder — the folder where all your hub repos live (e.g. ~/Projects/dokio/).

No install needed. Just run:

npx --yes create-dokio@latest

The --yes flag skips the "Ok to proceed?" prompt. The @latest tag ensures you always run the newest version — no separate update step needed.


Running the CLI

Interactive (recommended)

npx --yes create-dokio@latest

Prompts you to choose between creating a Template or a Hub.

Direct commands

# Go straight to template creation
npx --yes create-dokio@latest template

# Go straight to hub creation
npx --yes create-dokio@latest hub

Check version

npx --yes create-dokio@latest --version

Using pnpm instead of npx

pnpm dlx create-dokio

Commands

create-dokio hub

Creates a new hub repository locally with full structure, ready to push to GitHub.

Prompts:

  • Hub ID (kebab-case, e.g. bupa-sam)
  • Hub display name (e.g. Bupa Sales And Marketing Hub)

Generates:

bupa-sam-templates/
├── .husky/
│   ├── commit-msg        # Enforces conventional commits
│   └── post-commit       # Auto-updates template CHANGELOGs on commit
├── .vscode/
│   └── settings.json     # scss.validate: false, css.validate: false
├── templates/            # All templates live here
├── docs/
│   └── authoring.md      # Template authoring cheat-sheet
├── .gitignore
├── package.json          # pnpm project with husky prepare script
└── README.md

Next steps after hub creation:

cd bupa-sam-templates
pnpm install              # installs husky and activates hooks automatically

# Create the GitHub repo at github.com/dokioco/bupa-sam-templates, then:
git remote add origin https://github.com/dokioco/bupa-sam-templates
git push -u origin main

create-dokio template

Scaffolds a new template inside an existing hub repo. Automatically clones the hub if not found locally, or pulls latest if it is.

Prompts:

  • Template ID (e.g. HW485)
  • Template name (e.g. My Cool Template)
  • Template type — PDF, General, Email, or Video
  • Hub selection

What it does:

  • Clones or pulls the hub repo
  • Scaffolds the template folder inside <hub-id>-templates/templates/
  • Auto-repairs any missing hub tooling (hooks, .vscode, .gitignore, README.md)

create-dokio validate [--staged | <path>]

Validates templates against the upload contract (required fields, file structure, YAML correctness).

  • --staged — validates only the templates that have staged changes (useful in a pre-commit hook)
  • <path> — validates a specific template folder

create-dokio changelog

Runs the post-commit changelog step manually. Normally invoked automatically by the post-commit hook after every commit — only run this directly if you need to regenerate a changelog entry outside of a commit.


create-dokio ai-key [key]

Stores an Anthropic API key so the changelog generator writes AI descriptions instead of falling back to the commit subject. Run from inside a hub repo.

# pass the key directly
npx --yes create-dokio@latest ai-key sk-ant-...

# or omit it to be prompted (input is hidden)
npx --yes create-dokio@latest ai-key

Writes ANTHROPIC_API_KEY to a local .env (updating the line in place if it already exists) and ensures .env is gitignored. There is no built-in default key — bring your own from console.anthropic.com. The key stays on your machine and is never committed.


create-dokio repair

Migrates an existing hub to the current layout (husky + TypeScript tooling) and reinstalls dependencies. Use this on older hub repos that were scaffolded before the husky migration.

# from inside an existing hub repo (e.g. bupa-sam-templates/)
npx --yes create-dokio@latest repair

What it does:

  • Migrates .githooks/.husky/ and removes legacy Python tooling
  • Writes a package.json with the husky prepare script if absent
  • Runs pnpm install so hooks activate immediately

Safe to re-run any time — it never touches your template content.


Hooks work on clone now

Hub git hooks are managed by husky. After cloning a hub, pnpm install activates them automatically — no git config / no manual repair step required.

git clone https://github.com/dokioco/bupa-sam-templates
cd bupa-sam-templates
pnpm install    # hooks are live

Teammates on older hubs: if your hub predates the husky migration, run npx --yes create-dokio@latest repair once to upgrade it.


Template types

PDF

PrinceXML-rendered print documents. Supports multi-page, resizable layouts, orderable exports, and proof downloads.

Prompts: page dimensions (mm), page count, PrinceXML version (11 or 15), resizable, proof downloads, orderable export.

Generates:

HW485-my-cool-template/
├── CHANGELOG.md
├── data.yaml
├── index.html
├── assets/
├── partials/
│   ├── page1-cover.html
│   └── page2-content.html
└── scss/
    ├── style.scss.hbs
    ├── _fonts.scss
    ├── _mixins.scss
    ├── _variables.scss
    └── pages/
        ├── _page1.scss
        └── _page2.scss

General (image)

Chrome-rendered image output — JPG and/or PNG. Single or multi-section layouts.

Prompts: dimensions (px), page/section count, export formats (JPG, PNG, or both).


Email

HTML email scaffold. Includes Outlook conditional comments, {{{___assembled_css}}} injection, {{{subject}}} title, and Gmail-safe table structure.

Prompts: subdomain only — email structure is fixed at 600px.


Video (WIP)

1920×1080 video template scaffold. data.yaml includes duration and highlight point fields.


After scaffolding a template

# Navigate to the template folder
cd bupa-sam-templates/templates/HW485-my-cool-template

# 1. Check data.yaml — name and subdomain are auto-set, verify they're correct
# 2. Add assets to assets/
# 3. Edit partials/

# When ready to commit — go back to the hub root first:
cd ../../
git add templates/HW485-my-cool-template/
git commit -m "feat: add My Cool Template"
git push

Changelog generator

Each template has its own CHANGELOG.md. The post-commit hook runs create-dokio changelog automatically after every commit and:

  1. Detects which template folders changed
  2. Logs the commit to each affected template's CHANGELOG.md (author, date, branch, title, files with Added/Modified/Deleted labels)
  3. Amends the commit silently to include the changelog update

AI descriptions:

  • With ANTHROPIC_API_KEY set in the environment → Claude Haiku generates a summary
  • Without key → entry is logged without a description

Updating

Always use @latest when running the CLI — you're always on the newest version automatically. No separate update step.

npx --yes create-dokio@latest

Check what version is on npm:

npm show create-dokio version

Removing

If you ever installed create-dokio globally (via npm install -g), remove it with:

npm uninstall -g create-dokio

npx users have nothing to uninstall — npx doesn't permanently install packages.


Development

git clone https://github.com/dokioco/create-dokio
cd create-dokio
pnpm install
pnpm build       # compile to dist/
pnpm link --global

Commit format

Enforced by commitlint on every commit:

feat: add resizable PDF option
fix: correct page count in data.yaml
chore: update dependencies
docs: update README

Breaking changes:

feat!: redesign template API

License

Proprietary — internal use at Dokio only. See LICENSE.