Skip to content

Commit

Permalink
fix: add peerDependenciesMeta to mark optional deps (#2606)
Browse files Browse the repository at this point in the history
Some package managers such as yarn or pnpm require strict definitons
of project dependencies which does not play well with our `require_optional`
approach to peer optional dependencies. This change utilizes a relatively
new `peerDependenciesMeta` field to inform these package managers of 
these optional dependencies.

NODE-2867
  • Loading branch information
andreialecu committed Nov 5, 2020
1 parent cafaa1b commit 186090e
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions package.json
Expand Up @@ -23,6 +23,26 @@
"snappy": "^6.3.4",
"bson-ext": "^2.0.0"
},
"peerDependenciesMeta": {
"kerberos": {
"optional": true
},
"mongodb-client-encryption": {
"optional": true
},
"mongodb-extjson": {
"optional": true
},
"snappy": {
"optional": true
},
"bson-ext": {
"optional": true
},
"aws4": {
"optional": true
}
},
"dependencies": {
"bl": "^2.2.1",
"bson": "^1.1.4",
Expand Down

0 comments on commit 186090e

Please sign in to comment.