
Research
SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains
An emerging npm supply chain attack that infects repos, steals CI secrets, and targets developer AI toolchains for further compromise.
@antfu/install-pkg
Advanced tools
Install package programmatically. Detect package managers automatically (npm, yarn, bun and pnpm).
npm i @antfu/install-pkg
import { installPackage } from '@antfu/install-pkg'
await installPackage('vite', { silent: true })
MIT License © 2021 Anthony Fu
npm-install-package is a utility for installing npm packages programmatically. It provides a simple API to install packages and can be used as an alternative to @antfu/install-pkg. However, it may not offer as many features or as clean an API as @antfu/install-pkg.
yarn-install is a utility for programmatically installing packages using Yarn. It is similar to @antfu/install-pkg but specifically designed for Yarn users. It provides a straightforward API for adding dependencies to your project using Yarn.
npmi is a simple utility for installing npm packages programmatically. It offers basic functionality for adding dependencies to your project and can be used as an alternative to @antfu/install-pkg. However, it may lack some of the advanced features provided by @antfu/install-pkg.
FAQs
Install package programmatically.
The npm package @antfu/install-pkg receives a total of 2,350,073 weekly downloads. As such, @antfu/install-pkg popularity was classified as popular.
We found that @antfu/install-pkg demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
An emerging npm supply chain attack that infects repos, steals CI secrets, and targets developer AI toolchains for further compromise.

Company News
Socket is proud to join the OpenJS Foundation as a Silver Member, deepening our commitment to the long-term health and security of the JavaScript ecosystem.

Security News
npm now links to Socket's security analysis on every package page. Here's what you'll find when you click through.