Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
min-release-age=7
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,27 @@ This README explains how to build the component library, scaffold new components

---

## Dependency Cooldown (Supply Chain Security)

This repo enforces a **7-day dependency cooldown** via npm's `min-release-age` setting in `.npmrc`. Any package version published to the npm registry within the last 7 days is automatically excluded from dependency resolution. This mitigates supply chain attacks where malicious packages are uploaded and removed within hours.

```ini
# .npmrc
min-release-age=7
```

**How it works:** When running `npm install`, npm checks each candidate package version's publish date. Versions newer than 7 days are treated as if they don't exist. Packages already pinned in `package-lock.json` are unaffected.

**Requirements:** npm 11.10.0+ (on older npm, the setting is silently ignored).

**Overriding for urgent CVE patches:**

```bash
npm install <package>@<version> --min-release-age=0
```

---

## Developer release workflow

Use this checklist whenever you cut a `0.0.x-dev` build or validate changes before promotion to a stable release.
Expand Down
Loading