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

@nuanst-one/ngitdb

v0.1.3

Published

Git-native structured data layer for JSON resources in GitHub repositories.

Readme

nGitDB

nGitDB is a TypeScript library for teams that keep structured JSON data in Git repositories and need safe, reviewable updates.

It provides a small workflow-aware API for:

  • reading JSON resources by canonical resource path
  • applying deterministic partial patches
  • validating staged changes before commit
  • protecting human-owned fields from machine overwrite
  • isolating edits in branch-backed sessions
  • creating GitHub commits and pull requests for review workflows

Install

npm install @nuanst-one/ngitdb

GitHub Action

For Python-first or non-TypeScript workflows, run your generator first and let the nGitDB Action publish the review PR.

permissions:
  contents: write
  pull-requests: write

steps:
  - uses: actions/checkout@v4

  - name: Build nGitDB batch
    run: python scripts/build_ngitdb_batch.py --output tmp/ngitdb.batch.json

  - name: Publish nGitDB updates
    uses: nuanst-gmbh/nGitDB@v0
    with:
      batch-file: tmp/ngitdb.batch.json
      session-key: company-enrichment
      commit-message: Update generated company data
      pr-title: Update generated company data
      pr-body: Generated by nGitDB.
      resource-config: |
        {
          "baseBranch": "main",
          "resourceRoot": "data",
          "resources": {
            "companies": {
              "fileName": "company.json",
              "ownership": {
                "legalName": "human-owned",
                "machine": "machine-owned"
              }
            }
          }
        }

The batch file contains patch operations:

{
  "resources": [
    {
      "resourcePath": "companies/acme-gmbh",
      "patch": {
        "machine.summary": "Industrial supplier with operations in Berlin"
      }
    }
  ]
}

When this repository is private, enable GitHub Actions access for same-organization client repositories before using nuanst-gmbh/nGitDB@v0.

Example

import { createGitDB } from "@nuanst-one/ngitdb";

const db = createGitDB({
  repositoryRoot: process.cwd(),
  backend: { type: "github" },
  baseBranch: "main",
  resources: {
    companies: {
      fileName: "company.json",
      ownership: {
        legalName: "human-owned",
        machine: "machine-owned",
      },
    },
  },
});

await db.startSession("acme-gmbh");

await db.patch("companies/acme-gmbh", {
  "machine.summary": "Industrial supplier with operations in Berlin",
  "machine.lastEnrichedAt": "2026-04-21",
});

await db.commit("Enrich company profile for acme-gmbh");

const pullRequest = await db.createPullRequest({
  title: "Enrich acme-gmbh company profile",
});

In GitHub Actions, backend: { type: "github" } reads GITHUB_REPOSITORY and GITHUB_TOKEN by default. The workflow needs:

permissions:
  contents: write
  pull-requests: write

Install nGitDB as a package dependency in consumer repositories and run npm ci in CI. Directly cloning this repository is for nGitDB development, not the supported consumer install path. See the GitHub Actions guide for a minimal workflow, reusable workflow notes, and current resource-creation limits.

Documentation

AI Assistant Support

nGitDB ships consumer prompt recipes and a Codex plugin with reusable skills:

  • ngitdb-starter: start a new TypeScript project with nGitDB
  • ngitdb-integrator: add nGitDB to an existing JSON workflow
  • ngitdb-reviewer: review an nGitDB integration for safety gaps

The plugin source is available under plugins/ngitdb.

Current Status

The current implementation provides the V1 library surface with two supported backends:

  • backend: { type: "github" } creates or resumes a GitHub session branch, creates commits with the Git database API, and creates or updates a pull request.
  • backend: { type: "local" } or an omitted backend writes committed session artifacts under .ngitdb/sessions/... for offline development and tests.

Development

npm install
npm run build
npm run build:action
npm test

The package build emits TypeScript declarations plus an obfuscated/minified runtime bundle. The GitHub Action bundle is minified and verified before publish.