Skip to content

3 schematics-required packages undeclared in package.json #3746

Description

@armando-navarro

Description

The schematics bundled in the published @angular/fire package require three packages at runtime that the published package.json does not declare:

  • jsonc-parser, required by the ng add setup path on every run with a feature selected
  • @angular-devkit/core, required by the built setup entry point
  • @angular-devkit/architect, required by the ng deploy builder

With npm's default hoisting, the first two happen to resolve from the dependency trees of the declared @angular-devkit/schematics and @schematics/angular. @angular-devkit/architect is worse: it is not in the package's dependency closure at all, and resolves only when the app's own @angular/cli install provides it, a package @angular/fire declares no relationship with.

Impact

Under package managers that do not hoist undeclared packages (pnpm's default isolated layout, Yarn Plug'n'Play), ng deploy fails at module resolution. The other two work today by hoisting coincidence and are one dependency-graph change away from the same failure.

Versions

Verified against the published @angular/fire@21.0.0-rc.0 tarball. The same omissions exist in 20.0.1.

Expected behavior

Every package the shipped code requires at runtime is declared in the published manifest.

Metadata

Metadata

Assignees

No one assigned

    Labels

    comp: schematicsng add / deploy schematics (src/schematics).type: bugDefect: expected behavior doesn't happen.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions