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

@shipbench/core

v0.4.0

Published

Headless library for the ShipBench project convention — parse, validate, and write Markdown task files through a pluggable storage adapter.

Readme

@shipbench/core

The headless library behind ShipBench — Git-native project management where the task board lives in the repository as plain Markdown.

This package parses, validates, and writes that board. It has no filesystem access, no UI, and no network calls of its own: every read and write goes through a StorageAdapter you supply, so the same logic runs against a local checkout, the GitHub API, or an in-memory fixture in a test.

Most people want the shipbench CLI instead. Use this package when you are building a tool on top of the convention.

Install

npm install @shipbench/core

Usage

import { FsAdapter, loadConfig, listTasks, createTask } from '@shipbench/core';

const adapter = new FsAdapter(process.cwd());
const config = await loadConfig(adapter);

const { tasks, warnings } = await listTasks(adapter, config);

await createTask(adapter, config, {
  title: 'Build the API',
  priority: 'high',
  tags: ['backend'],
});

Adapters

Two implementations ship with the package:

  • FsAdapter — full read/write against the local filesystem.
  • GitHubAdapter — reads .shipbench/ through the GitHub Contents API. Cross-runtime, so it works in Node, browsers, and Cloudflare Workers.

The interface is deliberately small so additional hosts stay easy to add:

interface ReadableStorageAdapter {
  readFile(path: string): Promise<string>;
  readFileIfExists(path: string): Promise<string | null>;
  listFiles(directory: string): Promise<string[]>;
  readFiles(paths: string[]): Promise<Map<string, string>>;
}

interface StorageAdapter extends ReadableStorageAdapter {
  writeFile(path: string, content: string): Promise<void>;
  writeFiles(files: Map<string, string>): Promise<void>;
  deleteFile(path: string): Promise<void>;
}

Consumers that only display data should hold a ReadableStorageAdapter — it turns an accidental write into a compile error.

What it gives you

  • TaskscreateTask, getTask, updateTask, moveTask, reorderTask, deleteTask, listTasks, searchTasks
  • ArchivingarchiveTask, unarchiveTask, listArchivedTasks
  • DependencieslistAvailableTasks, listBlockedTasks, buildTaskDependencyGraph
  • CommentsaddComment, editComment, deleteComment
  • Config and setuploadConfig, validateConfig, initProject, DEFAULT_CONFIG
  • Slugsslugify, resolveSlugCollision

Design rules worth knowing

Strict on write, graceful on read. Invalid statuses and priorities are rejected on write. On read, a task with an unrecognized status comes back with a validation warning rather than being dropped — the board never silently loses work.

Unknown frontmatter is preserved. Core passes through fields it does not own, with a warning. It never strips data it did not write.

Timestamps are managed for you. created is set once; updated moves on every mutation. Both ISO 8601.

Partial configs are fine. config.json is deep-merged over DEFAULT_CONFIG at read time, so any field can be omitted.

The /layout subpath

Manual task ordering is shared contract, not private logic — hosts running optimistic updates must produce the same order core would write. It is exported from a pure subpath that imports only types:

import { orderedTasksForColumn, layoutAfterMove } from '@shipbench/core/layout';

Import ordering helpers from @shipbench/core/layout, never the package root — the root re-exports FsAdapter, which pulls in node:fs and will break a browser bundle.

License

MIT