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

synz-docs

v0.4.0

Published

A Bun-native Hono middleware that generates a docs site from markdown files

Readme

synz-docs

A Bun-native Hono middleware that generates a full documentation site from a folder of markdown files. No build step, no config files - just point it at a directory and go.

Live showcase available at labs.synz.xyz/showcase/docs

import { docs } from 'synz-docs'

app.route('/docs', docs({
    dir: './docs',
    title: 'My Project'
}))

features

  • Markdown rendered with syntax highlighting via Shiki

  • Sidebar navigation auto-generated from your folder structure

  • Frontmatter support for titles, ordering, descriptions, and visibility

  • Prev/next page navigation with section labels

  • Anchor links on headings

  • Built-in theme presets:

    • default
    • catppuccin
    • nord
    • rose-pine
    • synz
  • Fully customisable theme system via CSS variables

  • Configurable header subtitle or version badge

  • Built-in favicon support

  • Zero build step — reads files at startup


install

bun add synz-docs

usage

import { Hono } from 'hono'
import { docs } from 'synz-docs'

const app = new Hono()

app.route('/docs', docs({
    dir: './docs',
    title: 'My Project',
    basePath: '/docs'
}))

export default app

folder structure

Your dir folder maps directly to routes and sidebar sections:

docs/
├── index.md              → /docs
├── getting-started.md    → /docs/getting-started
└── api/
    ├── overview.md       → /docs/api/overview
    └── endpoints.md      → /docs/api/endpoints

Folders become sidebar section headers. Files become pages.


frontmatter

Each markdown file can include a frontmatter block at the top:

---
title: Getting Started
order: 1
description: How to get up and running
hidden: false
---

# Getting Started
...

| Field | Type | Description | | ----------- | ------- | --------------------------------------------------------------------------- | | title | string | Page title shown in the sidebar and browser tab. Falls back to filename. | | order | number | Sort order within the section. Lower numbers appear first. | | description | string | Short description used for meta tags. | | hidden | boolean | Hide this page from the sidebar while keeping it accessible via direct URL. |


themes

Pick a built-in preset or build your own.

docs({
    dir: './docs',
    title: 'My Project',
    theme: {
        preset: 'catppuccin'
    }
})

Available presets:

default
catppuccin
nord
rose-pine
synz

Override just the accent color:

theme: {
    preset: 'nord',
    accentColor: '#a3be8c'
}

Override CSS variables directly:

theme: {
    vars: {
        '--bg': '#0f0f0f',
        '--text': '#ffffff',
        '--font': '"IBM Plex Mono", monospace'
    }
}

Inject custom CSS:

theme: {
    customCss: `
        .header-logo {
            font-size: 1.25rem;
        }
    `
}

favicon support

synz-docs can automatically serve and inject a favicon.

docs({
    dir: './docs',
    title: 'My Project',
    favicon: './docs/favicon.png'
})

Supported formats include:

.png
.ico
.svg
.webp

The favicon is automatically exposed through the mounted docs route.

Example:

/docs/favicon.png

configuration

docs({
    dir: './docs',           // required — path to markdown files

    title: 'My Project',     // required — shown in header and page titles

    basePath: '/docs',       // optional — mounted route (default: '/docs')

    subtitle: 'API Docs',    // optional — text shown next to logo

    version: 'v1.0.0',       // optional — version badge shown instead of subtitle

    favicon: './docs/favicon.png', // optional — favicon asset path

    theme: {
        preset: 'default',        // optional — built-in theme preset

        accentColor: '#58a6ff',   // optional — overrides preset accent color

        logo: 'MY DOCS',          // optional — header logo text (default: title)

        vars: {                   // optional — CSS variable overrides
            '--bg': '#0f0f0f',
            '--font': '"IBM Plex Mono", monospace'
        },

        customCss: `              // optional — injected after base styles
            .header-logo {
                font-size: 1.25rem;
            }
        `
    }
})

callouts

Blockquotes are rendered as styled callout blocks:

> This is a callout. Use it for tips, warnings, or notes.

changelog

0.4.0

  • Added built-in favicon support
  • Added automatic favicon asset serving
  • Added support for .png, .ico, .svg, and .webp favicons

0.3.0

  • Added synz theme preset matching the synz.xyz terminal aesthetic
  • Added subtitle config option
  • Added version config option

0.2.0

  • Added built-in theme presets:

    • default
    • catppuccin
    • nord
    • rose-pine
  • Prev/next navigation now shows section labels

  • accentColor now overrides preset accent instead of replacing all theme vars

0.1.0

  • Initial release

license

MIT