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

@underwoodinc/requirements-tracer

v0.1.4

Published

Requirements traceability tool: scans test files, audits trace IDs against requirements-registry.yaml, generates a self-contained HTML report, and posts PR comments.

Downloads

850

Readme

@underwoodinc/requirements-tracer

Link every automated test to a requirement ID in a YAML registry, audit that link in CI, and publish a searchable HTML report on pull requests.

Companion to the Requirements Tracer GitHub Action. Requires Node.js 22+. MIT license.

Full documentation: github.com/Underwood-Inc/requirements-tracer-action/tree/main/docs · onboarding guide


Install

npm install -D @underwoodinc/[email protected]

Add scripts to package.json:

{
  "scripts": {
    "trace:audit": "trace audit --root . --config .traceability.yaml",
    "trace:report": "trace report --root . --config .traceability.yaml",
    "trace:scan": "trace scan --root . --config .traceability.yaml"
  }
}

What you need in the repo

| File | Purpose | |------|---------| | requirements-registry.yaml | Source of truth for requirement IDs (or shards via registryGlobs) | | .traceability.yaml | Test globs, kinds, trace-ID regex, report output paths | | Tagged tests | test('[FR-001] loads home view', …) — ID in the description string |

Kinds (FR, NFR, SEC, BR, custom keys like META, A11Y) are all first-class — not FR-only.

Minimal registry

schema_version: 1
requirements:
  FR-001:
    kind: FR
    title: Application loads home view
    status: active
  SEC-001:
    kind: SEC
    title: Session cookie is HttpOnly
    status: active

Minimal config

schema_version: 1
traceIdPattern: "\\[((?:[A-Z][A-Z0-9]*-)+\\d+)(?:,\\s*((?:[A-Z][A-Z0-9]*-)+\\d+))*\\]"
requireTraceId: error
kinds:
  FR:  { label: Functional }
  SEC: { label: Security }
testGlobs:
  - "**/*.test.ts"
  - "**/*.spec.ts"
output:
  reportDir: traceability-report
  reportEntry: index.html

CLI commands

npx trace audit --root .          # validate trace IDs; exit 1 on errors
npx trace report --root .         # write HTML + summary.json
npx trace scan --root .           # JSON dump of parsed tests
npx trace comment --root . --new  # PR comment (CI only)

Flags: --config .traceability.yaml, --registry requirements-registry.yaml, --strict (orphans / deprecated / unknown JSDoc tags → errors).

Report outputs

Written to output.reportDir (default traceability-report/):

| File | Purpose | |------|---------| | index.html | Self-contained searchable report (@untested, @sec, #tags, …) | | summary.json | Machine-readable counts for CI and automation | | audit.json | Raw audit findings |


GitHub Actions (recommended)

permissions:
  contents: read
  pull-requests: write   # PR comments
  checks: write          # inline diff annotations

jobs:
  traceability:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v6

      - uses: Underwood-Inc/[email protected]
        with:
          tracer-package: '@underwoodinc/[email protected]'
          token: ${{ secrets.GITHUB_TOKEN }}

The Action runs audit (with GitHub line annotations) → reportartifact uploadPR comment with a direct download link.

Custom PR comment? Set post-comment: 'false' and read summary.json from your report directory. Match report-dir to .traceability.yamloutput.reportDir. See ci-integration.md.


Programmatic API

Merge registry shards from Node scripts, Vite plugins, or custom report pipelines:

import {
  loadRequirementsRegistrySync,
  registryToJsonDocument,
} from '@underwoodinc/requirements-tracer/load-registry';

const registry = loadRequirementsRegistrySync({
  rootDir: process.cwd(),
  registryGlobs: ['requirements/*.yaml', 'src/**/*.fr.yaml'],
});

Optional JSDoc on tests

/**
 * @description Verifies checkout rejects expired sessions.
 * @owner platform
 * @priority high
 */
test('[SEC-001] expired JWT returns 401', () => { /* … */ });

Tag vocabulary: jsdoc-tags.md


Reference adopter

hello-desktop — minimal registry, Action wiring, and tagged Vitest tests.


Links

| Resource | URL | |----------|-----| | GitHub Action + source | https://github.com/Underwood-Inc/requirements-tracer-action | | Documentation index | https://github.com/Underwood-Inc/requirements-tracer-action/tree/main/docs | | npm | https://www.npmjs.com/package/@underwoodinc/requirements-tracer |


License

MIT — Underwood-Inc