Skip to content

Feature Request: Option to prevent auto bumping peerDependencies #970

Open
@SevenOutman

Description

@SevenOutman

The Problem

Hi team, thanks for making this tool! It's been helpful to keep our packages up-to-date in the monorepo.

One thing that turns out inconvenient is that, beachball does not seem to handle peerDependencies properly, by automatically bumping peerDependencies version when new versions are published.

For example, there is a base package and a feature package in the monorepo, and base is a peerDependencies of feature.

{
  "name": "@org/feature",
  "version": "1.0.0,
  "peerDependencies": {
    "@org/base": "^1.0.0"
  }
}

When publishing a new version of @org/base, say 1.1.0, beachball would update the feature's package.json to depended on the new version of base.

{
  "name": "@org/feature",
- "version": "1.0.0,
+ "version": "1.0.1,
  "peerDependencies": {
-   "@org/base": "^1.0.0"
+   "@org/base": "^1.1.0"
  }
}

This is not expected. Unlike dependencies, bumping peerDependencies version means that feature no longer works with the older version of base, which is both false and breaking.

This Proposal

Can we have an option say --bump-peer-deps for beachball bump and beachball publish that, when set to false, prevents beachball from bumping the peerDependencies versions.

Any thoughts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions