Skip to content

Commit 4ff403d

Browse files
fix(schematics): declare the runtime dependencies the schematics bundle requires (#3747)
The shipped schematics require jsonc-parser, @angular-devkit/core, and @angular-devkit/architect at runtime, but the published manifest never declared them. The first two resolve today only because npm hoists them from the declared @angular-devkit/schematics and @schematics/angular. Architect is worse: it is not in the package's dependency closure at all and resolves from the app's own @angular/cli install, so ng deploy breaks under pnpm's strict layout or Yarn PnP. The architect range is the comparator pair matching its 0.YYMM version scheme. A caret on a 0.x version would lock consumers to Angular 21.0.x. Also prunes the ng-packagr allowlist to the seven names actually declared, dropping ten entries for dependencies removed long ago and a duplicate @schematics/angular.
1 parent 5a6dc5e commit 4ff403d

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/ng-package.json

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,8 @@
55
},
66
"dest": "../dist/packages-dist",
77
"allowedNonPeerDependencies": [
8+
"@angular-devkit/architect", "@angular-devkit/core",
89
"@angular-devkit/schematics", "@schematics/angular",
9-
"fuzzy", "inquirer-autocomplete-prompt",
10-
"open", "jsonc-parser", "ora", "winston",
11-
"triple-beam", "@schematics/angular", "node-fetch",
12-
"semver", "inquirer", "fs-extra",
13-
"firebase", "rxfire"
10+
"jsonc-parser", "firebase", "rxfire"
1411
]
1512
}

src/package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,11 @@
4343
"dependencies": {
4444
"firebase": "^12.4.0",
4545
"rxfire": "^6.2.0",
46+
"@angular-devkit/architect": ">= 0.2100.0 < 0.2200.0",
47+
"@angular-devkit/core": "^21.0.0",
4648
"@angular-devkit/schematics": "^21.0.0",
4749
"@schematics/angular": "^21.0.0",
50+
"jsonc-parser": "^3.0.0",
4851
"tslib": "^2.3.0"
4952
},
5053
"ng-update": {

0 commit comments

Comments
 (0)