-
Notifications
You must be signed in to change notification settings - Fork 24.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(router): correctly deactivate children with componentless parent (#…
…40196) During route activation, a componentless route will not have a context created for it, but the logic continues to recurse so that children are still activated. This can be seen here: https://github.com/angular/angular/blob/362f45c4bf1bb49a90b014d2053f4c4474d132c0/packages/router/src/operators/activate_routes.ts#L151-L158 The current deactivation logic does not currently account for componentless routes. This commit adjusts the deactivation logic so that if a context cannot be retrieved for a given route (because it is componentless), we continue to recurse and deactivate the children using the same `parentContexts` in the same way that activation does. Fixes #20694 PR Close #40196
- Loading branch information
Showing
2 changed files
with
120 additions
and
20 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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