npm-ci-reproducibility

npm-ci-reproducibility is a cursor rule for coding agents from dmenchaca/webflow-to-react. It costs 0 tokens per session (390 once invoked), scanned C, original, MIT.

Rules for keeping npm dependencies and CI installs reproducible in a web project. CI is the automated system that builds and tests code, while npm ci installs the exact versions recorded in a lockfile.

In plain words
What is it for?
Updating package dependencies, regenerating and committing package-lock.json, testing clean installs and builds, and handling dependency version conflicts.
Why use it?
It prevents local machines and deployment systems from installing different dependency versions or failing because the lockfile is out of date.

Cursor rule

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/dmenchaca/webflow-to-react/npm-ci-reproducibility
Clone the repo
git clone --depth 1 https://github.com/dmenchaca/webflow-to-react

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for npm-ci-reproducibility

README.md
[![agentmods](https://agentmods.dev/badge/rules/dmenchaca/webflow-to-react/npm-ci-reproducibility.svg)](https://agentmods.dev/rules/dmenchaca/webflow-to-react/npm-ci-reproducibility)
Your own site
<a href="https://agentmods.dev/rules/dmenchaca/webflow-to-react/npm-ci-reproducibility"><img src="https://agentmods.dev/badge/rules/dmenchaca/webflow-to-react/npm-ci-reproducibility.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 390 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00390
Opus 5 $0.00000 $0.00195
Sonnet 5 $0.00000 $0.00078
Haiku 4.5 $0.00000 $0.00039

Measured 5d ago against content hash 730dfd1c9cd2, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade C, and why

npm-ci-reproducibility scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

cd web && rm -rf node_modules && npm ci && npm run build
rules/npm-ci-reproducibility.mdc · 22 lines

What it actually says

npm ci and reproducible installs (web/)

Netlify (and most CI) runs npm ci in web/ when web/package-lock.json exists. npm ci installs exactly what the lockfile pins — not “whatever npm install resolves today”.

Rules

  1. After any change to web/package.json or intentional dependency bump: run npm install inside web/, then verify npm ci from a clean tree:
    cd web && rm -rf node_modules && npm ci && npm run build
    
  2. Commit web/package-lock.json in the same commit as web/package.json changes.
  3. For repos that deploy, prefer exact versions (or tight ranges you control) on @tanstack/* and other core deps — avoid "latest" so installs stop drifting between laptops and CI.
  4. ETARGET / lock failures on CI: regenerate the lockfile locally after npm install; if a transitive stays broken, add a documented package.json overrides entry as a last resort.

Full context: gotchas.md § npm ci, lockfiles, and "latest", shipping.md § Lockfile and CI parity.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 22 lines · 0 tokens per session scan C 730dfd1c9cd2

Subscribe to this mod's changes

npm-ci-reproducibility is a cursor rule published in the GitHub repository dmenchaca/webflow-to-react (27 stars, last pushed 2mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 390 tokens. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.