Revision 9894278e712a50079af87898a63e1d19a462d015 authored by Andrew Kushnir on 17 April 2024, 00:10:08 UTC, committed by Alex Rickabaugh on 22 April 2024, 19:01:36 UTC
`RouterOutlet` uses a unique injector logic that returns a value that correspond to the `ActivatedRoute` token dynamically. This logic breaks when a component/directive/pipe that injects the `ActivatedRoute` is located within a `@defer` block, because defer creates an `EnvironmentInjector` instance, which doesn't have that dynamic logic. We've added some special handling of the `OutletInjector` in one of the previous commits, but it was incomplete and it was not covering cases when different routes use the same component. This commit updates defer logic to re-establish this dynamic behavior for `ActivatedRoute` by creating an instance of the `OutletInjector` when a parent injector was also an instance of `OutletInjector`. This fix is a short-term solution and longer term we should find a way to achieve the dynamic behavior that Router relies on, but without adding a special case logic into defer. Resolves #54864. PR Close #55374
1 parent aea5f05
renovate.json
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"baseBranches": ["main"],
"enabledManagers": ["npm", "bazel", "github-actions"],
"stopUpdatingLabel": "action: merge",
"rangeStrategy": "replace",
"pinDigests": true,
"semanticCommits": "enabled",
"semanticCommitScope": "",
"semanticCommitType": "build",
"dependencyDashboard": true,
"commitBody": "See associated pull request for more information.",
"separateMajorMinor": false,
"prHourlyLimit": 3,
"timezone": "America/Tijuana",
"lockFileMaintenance": {"enabled": true},
"labels": ["target: patch", "area: build & ci", "action: merge"],
"ignorePaths": ["aio/content/demos/first-app/package.json"],
"ignoreDeps": [
"@types/node",
"@types/selenium-webdriver",
"angular-1.5",
"angular-1.6",
"angular-1.7",
"angular-1.8",
"angular-mocks-1.5",
"angular-mocks-1.6",
"angular-mocks-1.7",
"angular-mocks-1.8",
"remark",
"remark-html",
"selenium-webdriver",
"watchr",
"rxjs",
"glob",
"chalk",
"convert-source-map",
"@rollup/plugin-node-resolve",
"hast-util-is-element",
"hast-util-has-property",
"hast-util-to-string",
"rehype-slug",
"rollup",
"systemjs",
"unist-util-filter",
"unist-util-source",
"unist-util-visit",
"unist-util-visit-parents",
"rules_pkg",
"aspect_bazel_lib"
],
"packageRules": [
{
"matchPackagePatterns": ["*"],
"matchUpdateTypes": ["minor", "patch"],
"groupName": "all non-major dependencies",
"schedule": ["after 10:00pm on monday", "before 04:00am on tuesday"]
},
{
"matchPackagePatterns": ["^@bazel/.*", "^build_bazel.*"],
"groupName": "bazel setup",
"schedule": ["at any time"]
},
{
"matchPackagePrefixes": ["@angular/", "angular/", "@angular-devkit", "@schematics/"],
"followTag": "next",
"groupName": "cross-repo Angular dependencies",
"schedule": ["at any time"]
},
{
"matchPackagePrefixes": ["@angular/", "angular/", "@angular-devkit", "@schematics/"],
"matchPaths": ["packages/**", "aio/tools/examples/shared/**"],
"followTag": null
},
{
"matchPackagePrefixes": ["@babel/", "@types/babel__"],
"groupName": "babel dependencies"
},
{
"matchPackagePrefixes": ["@angular-eslint/", "@typescript-eslint/"],
"groupName": "eslint dependencies"
},
{
"matchPackageNames": ["typescript", "tslib"],
"groupName": "typescript dependencies"
},
{
"matchPaths": [".github/workflows/scorecard.yml"],
"groupName": "scorecard action dependencies",
"groupSlug": "scorecard-action"
},
{
"matchPaths": ["aio/tools/examples/shared/*"],
"postUpgradeTasks": {
"commands": ["yarn --cwd=aio/tools/examples/shared run sync-deps"],
"fileFilters": ["aio/tools/examples/shared/boilerplate/**"]
}
},
{"matchCurrentVersion": "0.0.0-PLACEHOLDER", "enabled": false},
{"matchPaths": ["integration/**", "packages/zone.js/test/typings/package.json"], "enabled": false}
]
}
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...