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

@leansoftx/asdm-docs-viewer

v0.1.4

Published

Lightweight self-hosted Markdown documentation viewer with responsive UI, shareable URLs, and persistent tree state

Readme

asdm-docs-viewer

A lightweight, self-hosted documentation viewer for browsing Markdown-based docs directories in the browser. Built with Express + marked + highlight.js, with a responsive mobile UI, shareable URLs, and persistent tree state.

Features

  • Sidebar file tree with collapse/expand, persisted per-browser via localStorage
  • Markdown rendering with GitHub-flavored markdown, syntax-highlighted code blocks, images, tables, blockquotes
  • URL hash routing — shareable deep links (/#/path/to/file.md) so others land on the exact document
  • Mobile responsive — hamburger menu, slide-out sidebar, auto-close on file select, wrapped code blocks (no horizontal page overflow)
  • SVG file-type icons (folder / markdown / image / code / generic), no emoji, colored by type
  • Tree connector lines and visual differentiation between expanded/collapsed directories
  • Forward/back history via hashchange events
  • CLI — point at any docs directory, choose port/host, auto-open browser

Install

npm install -g @leansoftx/asdm-docs-viewer

Usage

# Point at a directory of Markdown docs
asdm-docs-viewer ./docs

# Choose port + auto-open browser
asdm-docs-viewer ~/projects/my-repo/docs --port 8080 --open

# Use env vars instead of args
DOCS_ROOT=./docs PORT=8080 asdm-docs-viewer

Then open http://localhost:5060 (or the port you chose). Shareable URLs look like:

http://localhost:5060/#/path/to/file.md

CLI reference

asdm-docs-viewer [path-to-docs] [options]

Arguments:
  path-to-docs     Path to the directory containing Markdown docs.
                   Defaults to $DOCS_ROOT or ./docs.

Options:
  --port <n>       HTTP port (default: 5060, or $PORT)
  --host <addr>    Bind address (default: 0.0.0.0, or $HOST)
  --open           Open the browser after start
  --help, -h       Show help
  --version, -v    Print version

Environment:
  DOCS_ROOT         Same as the positional path argument
  PORT              Same as --port
  HOST              Same as --host

Develop

git clone [email protected]:asdm-ai/asdm-docs-viewer.git
cd asdm-docs-viewer
npm install
npm run dev -- --docs ./path/to/docs

Tech stack

  • Runtime: Node.js (>= 18)
  • Server: Express
  • Markdown: marked
  • Syntax highlight: highlight.js
  • Frontend: vanilla HTML/CSS/JS (no bundler, no framework)

Roadmap

  • [ ] Dark mode theme toggle
  • [ ] Optional .docs-viewer.json for per-repo customization (title, ignored globs, default expansion)
  • [ ] Inline-bundle client (esbuild) for single-file distribution
  • [ ] Optional Node SEA single-executable binary

Not in scope

  • Multi-root serving (serving multiple docs directories from one instance)
  • Authentication / access control
  • Full-text search across document bodies (filename filter only for now)

License

MIT — see LICENSE.