Skip to content

eliminate phantom dependencies #833

@turadg

Description

@turadg

Problem

Phantom dependencies are allowed by the Yarn 1 package manager in use.

It can lead to problems for package consumers that aren't evident in the monorepo tests. For example,

Solution

use a package manager configured to prevent phantom dependencies. Some options:

  • pnpm
  • Yarn 4 with nodeLinked: pnpm
  • Yarn 4 with nmHoistingLimits: workspaces

In changing some builds or tests may fail at first. That means they have undeclared dependencies. The solution is just to declare them. For intra-repo deps, the workspace: protocol works well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions