Skip to content

craftA fast, strict package manager for Node.js

Written in Rust. Installs from npm into an isolated node_modules, keeps a deterministic lockfile, and runs install scripts only for packages you trust.

craft

Install โ€‹

sh
curl -fsSL https://raw.githubusercontent.com/craftpkg/craft/main/install.sh | bash

Then, in a project:

sh
craft install          # install everything in package.json
craft add react        # add a dependency
craft run build        # run a script

See Installation for release binaries, Windows and building from source.

Benchmarks โ€‹

craft against npm, pnpm and Yarn on the largest project in the benchmark:

A Next.js app with a design system, cloud SDKs, Storybook, Jest, Playwright and a webpack toolchain, 1,391 packages ยท mean wall time, lower is better

Warm cache and lockfile

craft1.72 s best
npm7.26 s 4.2ร—
pnpm1.80 s 1.05ร—
yarn7.67 s 4.5ร—

Warm cache, no lockfile

craft1.78 s best
npm12.38 s 6.9ร—
pnpm1.91 s 1.07ร—
yarn9.58 s 5.4ร—

Cold: no cache, no lockfile

craft18.38 s best
npm62.98 s 3.4ร—
pnpm28.82 s 1.6ร—
yarn29.97 s 1.6ร—

Already installed

craft5.9 ms best
npm673 ms 114ร—
pnpm35 ms 6.0ร—
yarn900 ms 152ร—

Every project, scenario and peak memory, and how it's kept fair: Benchmarks.

Released under the MIT License.