
Security News
TypeScript is Porting Its Compiler to Go for 10x Faster Builds
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
🌈 Unified Package Manager for Node.js (npm, pnpm, yarn), Bun and Deno.
✅ Supports npm, yarn, pnpm and bun and deno out of the box with a unified API.
✅ Provides an API interface to interact with package managers.
✅ Autodetects project's package manager using package.json
and known lockfiles.
✅ corepack integration for pnpm and yarn.
nypm
commandInstall dependencies:
npx nypm i
Add a dependency:
npx nypm add defu
Remove a dependency:
npx nypm remove defu
Install package:
# ✨ Auto-detect
npx nypm install nypm
# npm
npm install nypm
# yarn
yarn add nypm
# pnpm
pnpm install nypm
# bun
bun install nypm
# deno
deno install nypm
Import:
// ESM import
import { addDependency } from "nypm";
// or dynamic import
const { addDependency } = await import("nypm");
addDependency(name, options)
Adds dependency to the project.
addDevDependency(name, options)
Adds dev dependency to the project.
detectPackageManager(cwd, options)
Detect the package manager used in a directory (and up) by checking various sources:
packageManager
field from package.jsonensureDependencyInstalled(name, options)
Ensures dependency is installed.
installDependencies(options)
Installs project dependencies.
removeDependency(name, options)
Removes dependency from the project.
dedupeDependencies(options)
Dedupe project dependencies.
runScript(name, options)
Runs a script defined in the package.json
file.
[!NOTE] For
bun
anddeno
it will remove the lockfile and reinstall all dependencies.
corepack enable
pnpm install
pnpm dev
NYPM is inspired from previous attempts and projects for unifying package manager experience.
Made with 💛
Published under MIT License.
v0.6.0
runScript
utility (#191)exitCode
for failed commands (2d6cfbf)install
for yarn v1 (8ec61f3)majorVersion
(#193)ufo
dependency (b295f7e)exitCode
for failed commands (2d6cfbf)majorVersion
(#193)FAQs
Unified Package Manager for Node.js
The npm package nypm receives a total of 2,879,450 weekly downloads. As such, nypm popularity was classified as popular.
We found that nypm 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.
Security News
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.