Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fix(migrations): replace leftover modules with their exports during pruning #57684

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed

Conversation

crisbeto
Copy link
Member

@crisbeto crisbeto commented Sep 6, 2024

Currently during the module pruning stage of the standalone migration we assume that any leftover modules which only have imports and exports can safely be removed. That can be incorrect for the cases where some parts of the app were converted to standalone outside of the migration.

These changes update the logic so that such modules are replaced with the exports which are used within the specific component.

Fixes #51420.

…runing

Currently during the module pruning stage of the standalone migration we assume that any leftover modules which only have `imports` and `exports` can safely be removed. That can be incorrect for the cases where some parts of the app were converted to standalone outside of the migration.

These changes update the logic so that such modules are replaced with the `exports` which are used within the specific component.

Fixes angular#51420.
@crisbeto crisbeto added target: patch This PR is targeted for the next patch release area: migrations Issues related to `ng update` migrations labels Sep 6, 2024
@crisbeto crisbeto requested a review from devversion September 6, 2024 08:56
@ngbot ngbot bot modified the milestone: Backlog Sep 6, 2024
@crisbeto crisbeto added the action: review The PR is still awaiting reviews from at least one requested reviewer label Sep 6, 2024
@crisbeto crisbeto 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 Sep 6, 2024
@thePunderWoman
Copy link
Contributor

This PR was merged into the repository by commit fc95a9a.

The changes were merged into the following branches: main, 18.2.x

thePunderWoman pushed a commit that referenced this pull request Sep 6, 2024
…runing (#57684)

Currently during the module pruning stage of the standalone migration we assume that any leftover modules which only have `imports` and `exports` can safely be removed. That can be incorrect for the cases where some parts of the app were converted to standalone outside of the migration.

These changes update the logic so that such modules are replaced with the `exports` which are used within the specific component.

Fixes #51420.

PR Close #57684
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Oct 7, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker area: migrations Issues related to `ng update` migrations target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

standalone migration's prune-ng-modules mode doesn't update standalone imports
3 participants