Repository navigation
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the Angular app-shell schematic to explicitly set the component type option to an empty string (type: ''). This prevents the generated app-shell component from inheriting a custom component type from the workspace defaults, which would otherwise alter the file and class names and break the expected AppShell import. Additionally, a unit test has been added to verify this behavior by emulating workspace defaults. There are no review comments to address, and the changes look solid.
`ng generate app-shell` adds an `AppShell` import from `./app-shell/app-shell`, but the component it
generates inherits the workspace `type` option. In workspaces that set
`"@schematics/angular:component": { "type": "component" }`, such as those updated to v20, the
component was generated as `app-shell.component.ts` and the import failed to resolve.
Pass an empty `type`, as the library schematic does (661609e).
Refs angular#34449
MeAkib
force-pushed
the
fix/app-shell-component-type
branch
from
October 20, 2026 18:13
7ece3b8 to
c7f3fce
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ng generate app-shelladds anAppShellimport from./app-shell/app-shell, but the component it generates inherits the workspacetypeoption. In workspaces that set"@schematics/angular:component": { "type": "component" }, such as those updated to v20, the component was generated asapp-shell.component.tsand the import failed to resolve.Pass an empty
type, as the library schematic does (661609e).Fixes #34449