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

@asahi-fj/structcms

v0.1.6

Published

GitHub as a CMS — fetch, transform, render content via GitHub API

Downloads

433

Readme

structcms

Use GitHub as a headless CMS. Fetch and transform content stored in a GitHub repository via the GitHub API.

Why structcms?

structcms treats a GitHub repository as your content store — no extra infrastructure, no vendor lock-in.

| Feature | structcms | Outstatic | Decap CMS | Contentlayer | |---|---|---|---|---| | Zero added infrastructure | ✅ No DB, no server | ✅ | ⚠️ Needs Git Gateway / Netlify | ✅ | | Separate content & app repos | ✅ Any repo, any owner | ❌ Same repo only | ⚠️ Manual config | ❌ Local files only | | Private repository support | ✅ Token-based access | ❌ Public repos only | ⚠️ Limited | ✅ | | Setup requirement | GitHub Token only | GitHub OAuth App | Netlify / OAuth | Local file system |

How it works

Store content under a contents/ directory in any GitHub repository. Each piece of content lives in its own slug-named folder with a Markdown file and a JSON metadata file.

your-content-repo/
└── contents/
    ├── hello-world/
    │   ├── content.md
    │   └── meta.json
    └── my-second-post/
        ├── content.md
        └── meta.json

Installation

npm install @asahi-fj/structcms

Quick start

import StructCms from "@asahi-fj/structcms";

const cms = StructCms({
  token: process.env.GITHUB_TOKEN!,
  owner: "your-org",
  repo: "your-content-repo",
});

const posts = await cms.getAll();
// [{ slug: "hello-world", content: "# Hello\n...", meta: { title: "Hello World", ... } }]

See USAGE.md for full examples.

Content format

meta.json

{
  "title": "Post title",
  "description": "A short description",
  "publishedAt": "2026-04-11",
  "draft": false,
  "tags": ["typescript", "cms"]
}

content.md — standard Markdown.

API

| Method | Description | |---|---| | cms.getAll() | Fetch all content entries | | cms.getById(id) | Fetch a single entry by slug (coming soon) |

Requirements

  • Node.js 18+
  • GitHub Personal Access Token with read access to the content repository

License

ISC