mirror of
https://github.com/oven-sh/bun
synced 2026-02-02 15:08:46 +00:00
724 B
724 B
name
| name |
|---|
| Add a peer dependency |
To add an npm package as a peer dependency, use the --peer flag.
$ bun add @types/bun --peer
This will add the package to peerDependencies in package.json.
{
"peerDependencies": {
+ "@types/bun": "^$BUN_LATEST_VERSION"
}
}
Running bun install will install peer dependencies by default, unless marked optional in peerDependenciesMeta.
{
"peerDependencies": {
"@types/bun": "^$BUN_LATEST_VERSION"
},
"peerDependenciesMeta": {
+ "@types/bun": {
+ "optional": true
+ }
}
}
See Docs > Package manager for complete documentation of Bun's package manager.