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

@marklab/cli

v0.1.0-alpha.5

Published

Local-first MarkLab CLI for opening, sharing, and joining Markdown collaboration sessions.

Downloads

753

Readme

MarkLab CLI

Alpha CLI package for running MarkLab's local-first Markdown collaboration flow.

npx -y @marklab/cli open README.md --background
npx -y @marklab/cli create-link README.md --role edit
npx -y @marklab/cli join '<edit-link>' --pick-dir --background

Requirements

  • Node.js 20.19 or newer, Node.js 22.12 or newer, or Node.js 24 or newer.
  • A modern browser.
  • The npm package includes the CLI runtime for open, share, and join. Developers working from the repository checkout can still use pnpm for local development.

Ordinary collaborators using a hosted edit link do not need Postgres, Docker, pnpm, Git, or a specific Markdown editor.

Commands

marklab open <file.md>
marklab open <file.md> --background
marklab create-link <file.md> --role edit
marklab create-link <file.md> --role view
marklab share <file.md>
marklab join <edit-link> <file.md>
marklab join <edit-link> --pick-dir --background
marklab join <edit-link> --dir ./docs --create-dir --background
marklab status
marklab stop <file.md>
marklab stop --all

Use marklab --help, marklab open --help, marklab create-link --help, marklab share --help, or marklab join --help for command help.

Host Online Behavior

Host online means the MarkLab daemon is running and connected.

Use persistent background hosting for normal collaboration:

marklab open <file.md> --background
marklab create-link <file.md> --role edit

Hosting continues after the terminal command exits until you run marklab stop <file.md> or marklab stop --all. Closing the browser tab does not stop hosting as long as the daemon process is still running.

marklab share <file.md> is temporary foreground sharing. Closing that terminal stops hosting, so use it for quick tests rather than persistent collaboration.

Browser edit and view links work without installing MarkLab. A pure web link cannot install or run a local CLI, create local files, or inspect whether local software is available, because browsers do not have that access. The current safe alpha path is one relay link plus a copyable one-line npx command for collaborators who want a local mirror.

Edit links can be used in the browser or with marklab join. View links are browser-only and cannot create local mirrors. To choose the destination folder with a system dialog and create a background local Markdown mirror, use an edit link:

marklab join <edit-link> --pick-dir --background

The collaborator can also type a folder instead:

marklab join <edit-link> --dir ./docs --create-dir --background

The collaborator chooses the destination folder; MarkLab uses the host file name from the edit link. Background join opens the local browser URL, then returns after the mirror daemon starts. Omit --background for foreground join and keep the terminal open while you want the mirror to sync. Stop a background mirror with marklab stop ./docs/README.md, or stop every local MarkLab daemon with marklab stop --all.

marklab join rejects view links and host-offline links before creating directories, writing files, starting a watcher, or connecting a daemon.

Relay URL Configuration

The packaged alpha CLI defaults share links to the hosted Fly relay:

MARKLAB_PUBLIC_WEB_URL=https://marklab-relay-alpha.fly.dev
MARKLAB_PUBLIC_API_URL=https://marklab-relay-alpha.fly.dev
MARKLAB_PUBLIC_RELAY_WS_URL=wss://marklab-relay-alpha.fly.dev/relay

Normal users do not need to set those variables. Operators and self-hosted testers can override the public relay URLs by setting all three values together:

MARKLAB_PUBLIC_WEB_URL=https://marklab-relay-alpha.fly.dev \
MARKLAB_PUBLIC_API_URL=https://marklab-relay-alpha.fly.dev \
MARKLAB_PUBLIC_RELAY_WS_URL=wss://marklab-relay-alpha.fly.dev/relay \
marklab share README.md

When public URLs are configured, MarkLab requires all three values together and rejects loopback public URLs. Production relay WebSocket URLs must use wss://.

To force local loopback relay URLs while developing from this repository, set:

MARKLAB_RELAY_MODE=development