Skip to content

fix(@schematics/angular): reject ng-packagr builders in entry-point schematic - #34680

Merged
clydin merged 1 commit into
angular:mainfrom
alan-agius4:fix/entry-point-ng-packagr-check
Nov 11, 2026
Merged

clydin merged 1 commit into
angular:mainfrom
alan-agius4:fix/entry-point-ng-packagr-check

Conversation

@alan-agius4

Copy link
Copy Markdown
Collaborator

Validates that a library project is not configured to use @angular/build:ng-packagr or @angular-devkit/build-angular:ng-packagr in the entry-point schematic instead of strictly requiring @angular/build:library, allowing custom library builders or workspaces without a build target.

…chematic

Validate that a library project is not configured with either `@angular/build:ng-packagr` or `@angular-devkit/build-angular:ng-packagr` instead of strictly requiring `@angular/build:library`. This prevents running the `entry-point` schematic on legacy `ng-packagr` projects while allowing custom library builders or workspaces without a `build` target.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the entry-point schematic to allow library projects that use custom builders or have no build target. Instead of strictly requiring the build target to use the BuildLibrary builder, it now checks all targets and only throws an exception if an unsupported ng-packagr builder is detected. Additionally, corresponding unit tests have been added to verify support for custom builders, missing build targets, and unsupported builders. There are no review comments to address.

@alan-agius4 alan-agius4 added action: review The PR is still awaiting reviews from at least one requested reviewer target: minor This PR is targeted for the next minor release labels Nov 11, 2026
@alan-agius4
alan-agius4 requested a review from clydin November 11, 2026 11:08
@alan-agius4 alan-agius4 added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Nov 11, 2026
@clydin
clydin merged commit c4028e8 into angular:main Nov 11, 2026
43 checks passed
@clydin

clydin commented Nov 11, 2026

Copy link
Copy Markdown
Member

This PR was merged into the repository. The changes were merged into the following branches:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action: merge The PR is ready for merge by the caretaker area: @schematics/angular target: minor This PR is targeted for the next minor release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants