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

docs-agents-md

v0.1.7

Published

Download documentation from any GitHub repo and generate a compact index for AI coding agents

Readme

docs-agents-md

Give your AI coding agent the docs it needs — in one command.

npm version license node

npx docs-agents-md

Downloads docs from any GitHub repo and injects a compact, token-optimized index into your AGENTS.md or CLAUDE.md — so your AI agent uses real docs instead of hallucinating.

Get Started

# Pick from 20+ presets interactively
npx docs-agents-md

# Or one-liner
npx docs-agents-md --lib nextjs

# Any GitHub repo
npx docs-agents-md --repo vercel/next.js --name nextjs --docs-path docs

Presets

20 frameworks built-in. Run npx docs-agents-md list to see all.

| | | | | | -------------- | -------- | -------- | ---------------- | | nextjs | react | vue | svelte | | angular | nuxt | astro | tailwindcss | | drizzle | prisma | nestjs | express | | fastify | hono | trpc | tanstack-query | | react-router | vite | bun | zustand |

Missing one? Use --repo for any GitHub repo, or open an issue.

What It Does

  1. Downloads only the docs folder via git sparse-checkout (fast, minimal)
  2. Indexes all doc files into a single-line, pipe-separated format (minimal tokens)
  3. Injects into your agent file with namespaced markers (multiple libs coexist)
  4. Auto-detects your installed version to match the right docs tag
  5. Gitignores the cache directory automatically

Multiple Libraries

Each library gets its own marker block — they coexist and update independently:

npx docs-agents-md --lib react --output AGENTS.md
npx docs-agents-md --lib drizzle --output AGENTS.md
npx docs-agents-md --lib tailwindcss --output AGENTS.md

Options

| Flag | Description | Default | | --------------------- | ------------------------------------- | --------------- | | --lib <name> | Built-in preset | — | | --repo <owner/repo> | Any GitHub repository | — | | --name <name> | Library name (required with --repo) | — | | --tag <tag> | Git tag or branch | main / preset | | --docs-path <path> | Docs folder in repo | docs | | --output <file> | Target file | AGENTS.md | | --extensions <exts> | File types to index | md,mdx |

Set GITHUB_TOKEN env var for higher API rate limits (5,000/hr vs 60/hr).

Inspiration

Inspired by Vercel's research on AGENTS.md, which showed that documentation context via AGENTS.md significantly outperforms other approaches in agent evaluations.

Contributing

  1. Add an entry to src/lib/registry.ts
  2. Run npm test
  3. Open a PR

License

MIT