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

@dominic.mayers/last-of-readme

v0.1.84

Published

Resolve README to last relevant commit based on npm version

Readme

Last of README

npm version

Last of Readme helps package maintainers publish README links that continue to resolve correctly across package versions and documentation updates.

Instead of linking directly to a mutable README location, Last of Readme maintains resolver links backed by Git tags and explicit documentation contracts.

[!NOTE] For detailed installation behavior, runtime orchestration, architectural layering, resolver semantics, and design rationale, see ARCHITECTURE.md.

ARCHITECTURE.md is also currently used as a structured context for AI-assisted code analysis and development.

Interactive demo

An interactive demo lets you explore the full workflow in the browser: bumping a version, inserting a resolver link, publishing, and clicking the badge to see how the resolver selects the right README.

Documentation contracts

Last of Readme manages README resolver links through documentation contracts.

These contracts determine how the documents presented through the README link evolve as newer versions and documentation corrections are published.

Last of Readme currently supports five contracts:

  • until-next
  • until-next-warn
  • until-branch
  • until-branch-warn
  • correction-of

The until-next, until-next-warn, until-branch, and until-branch-warn contracts use the successor-of and last-of tags, but they interpret them differently. The correction-of contract uses only the correction-of tag.

The last-of and correction-of tags are normally added manually by maintainers. The successor-of tag is normally added automatically at the next version bump.

until-next

Resolution order:

  1. last-of tag
  2. successor-of tag
  3. HEAD of the single containing branch
  4. options when several containing branches exist
  5. package version

In this contract, either a last-of tag or a successor-of tag is sufficient to directly present documentation, even when many branch alternatives exist.

Documentation presented through a successor-of tag or through the HEAD of a single containing branch is presented without warning.

until-next-warn

Resolution order (same as until-next):

  1. last-of tag
  2. successor-of tag
  3. HEAD of the single containing branch
  4. options when several containing branches exist
  5. package version

In this contract, as for until-next, either a last-of tag or a successor-of tag is sufficient to present documentation even when many branch alternatives exist.

Documentation presented without a last-of tag is presented with a warning.

until-branch

Resolution order:

  1. last-of tag
  2. options when several containing branches exist
  3. successor-of tag
  4. HEAD of the single containing branch
  5. package version

In this contract, only a last-of tag is sufficient to directly present documentation when many branch alternatives exist.

Documentation presented without a last-of tag is presented without warning.

until-branch-warn

Resolution order (same as until-branch):

  1. last-of tag
  2. options when several containing branches exist
  3. successor-of tag
  4. HEAD of the single containing branch
  5. package version

In this contract, as in until-branch, only a last-of tag is sufficient to directly present documentation, even when many branch alternatives exist.

Documentation presented without a last-of tag is presented with a warning.

correction-of

The resolver first looks for a correction-of tag associated with the package version.

If none exists, the resolver uses the package version itself.

This contract supports workflows where documentation associated with a package version may later receive explicit corrections while remaining attached to that version.


Installation

Install Last of Readme in a package repository:

npm i --save-dev @dominic.mayers/last-of-readme

Then run:

npx last-of-readme install

The installer configures:

  • README placeholder management,
  • package.json integration,
  • runtime lifecycle hooks,
  • remote repository configuration.

Typical workflow

Choose the contract for the next version:

npx last-of-readme contract until-next

Then bump the version normally:

npm version patch

During the version lifecycle, Last of Readme:

  • validates the documentation contract,
  • updates the managed README resolver link,
  • creates the appropriate documentation tags.

Commands

last-of-readme install
last-of-readme contract <until-next|until-next-warn|until-branch|until-branch-warn|correction-of>
last-of-readme check-contract
last-of-readme tag-doc <last-of|successor-of|correction-of>
last-of-readme update-readme-link

Repository structure

scripts/last-of-readme/
├── adapters/
├── install/
├── bin/
├── attempt-*.cjs
├── check-contract.cjs
├── tag-doc.cjs
└── update-readme-link.cjs

Architecture and design

The ARCHITECTURE document provides a more detailed account of the project architecture and design, including:

  • installation orchestration,
  • runtime-management wrappers,
  • adapter layering,
  • resolver management,
  • environment-part decomposition,
  • and architectural rationale.