Affected Packages
TBH I'm not sure which package handles this. @changesets/assemble-release-plan?
Problem
There are two packages in a monorepo, foo and bar. Notice that their version have major version 0 and that bar depends on foo via peer dependnecy:
{
"name": "foo",
"version": "0.1.0"
}
{
"name": "bar",
"version": "0.1.0",
"peerDependencies": {
"foo": "^0.1.0"
}
}
Let's create new changeset:
---
'foo': minor
---
New feature makes Foo better!
When running npx changeset version, foo is bumped to 0.2.0, that means peer dependency in bar/package.json must change to ^0.2.0, which is a breaking change (because that's how caret ranges work in https://www.npmjs.com/package/semver), so bar version is bumped too - to 1.0.0. But since we're still in 0.x versions, bumping bar to 0.2.0 would suffice (it is allowed to make breaking changes when major version is zero according to https://semver.org/).
Proposed solution
In this situation, bar is bumped to 0.2.0, not 1.0.0.
Affected Packages
TBH I'm not sure which package handles this. @changesets/assemble-release-plan?
Problem
There are two packages in a monorepo,
fooandbar. Notice that their version have major version 0 and thatbardepends onfoovia peer dependnecy:{ "name": "foo", "version": "0.1.0" }{ "name": "bar", "version": "0.1.0", "peerDependencies": { "foo": "^0.1.0" } }Let's create new changeset:
When running
npx changeset version,foois bumped to0.2.0, that means peer dependency inbar/package.jsonmust change to^0.2.0, which is a breaking change (because that's how caret ranges work in https://www.npmjs.com/package/semver), sobarversion is bumped too - to1.0.0. But since we're still in 0.x versions, bumpingbarto0.2.0would suffice (it is allowed to make breaking changes when major version is zero according to https://semver.org/).Proposed solution
In this situation,
baris bumped to0.2.0, not1.0.0.