# Safe-install – safer NPM installs with trusted build depend…

In light of the ongoing npm supply chain compromises, I built safe-install: https://www.npmjs.com/package/@gkiely/safe-install It brings a couple of protections I wanted from npm but are not built in. Similar to Bun’s trusted dependencies, it lets you disable install scripts by default and define a…

- **Page:** https://magpie.gallery/i/safe-install-safer-npm-installs-with-trusted-build-6g26
- **Type:** Link to an idea elsewhere
- **Category:** AI & dev
- **Tags:** npm, security, supply-chain, install-scripts

## Source

Web · gkiely: Safe-install – safer NPM installs with trusted build dependencies

- **Original:** https://news.ycombinator.com/item?id=48102636

> In light of the ongoing npm supply chain compromises, I built safe-install: https://www.npmjs.com/package/@gkiely/safe-install It brings a couple of protections I wanted from npm but are not built in. Similar to Bun’s trusted dependencies, it lets you disable install scripts by default and define a list of dependencies that are allowed to run build/install scripts: https://bun.com/docs/guides/install/trusted It also supports blocking exotic sub-dependencies, similar to pnpm’s `blockExoticSubdeps` setting: https://gajus.com/blog/3-pnpm-settings-to-protect-yourself-f... I was hoping npm would eventually add something like this, but it does not seem to be happening soon, so I made a small package for it. https://www.npmjs.com/package/@gkiely/safe-install

## Rules for reuse

- Build your own version: don't copy another product's code, look, icons, colours or copy.
- The original belongs to its author; Magpie only links to it.
- The original content's copyright belongs to its creator. Magpie doesn't download or re-upload it; we only show the link and the official preview.
