angular/packages/core/testing
Kristiyan Kostadinov 886cf6c452 fix(core): unable to inject viewProviders when host directive with providers is present
When registering providers, the DI system assumes that `viewProviders` are registered before plain `providers`. This was reinforced by components always being first in the array of directive matches, only one component being allowed per node and the fact that only components can have `viewProviders`.

This breaks down if there are host directives with `providers` on the component, because they'll execute earlier, throwing off the order of operations.

These changes fix the issue by separating out the resolvers for `viewProviders` and plain `providers` and explicitly running the component's `viewProviders` resolver before any others. This also has the benefit of not attempting to resolve `viewProviders` for directives which are guaranteed not to have them.

Fixes #65724.
2025-12-03 15:09:48 +01:00
..
src fix(core): unable to inject viewProviders when host directive with providers is present 2025-12-03 15:09:48 +01:00
BUILD.bazel refactor(bazel): reduce build deps (#63348) 2025-08-28 09:16:10 -07:00
index.ts refactor: update license text to point to angular.dev (#57901) 2024-09-24 15:33:00 +02:00
PACKAGE.md build: format md files 2025-11-06 10:03:05 -08:00
public_api.ts build: migrate platform-browser and platform-browser-dynamic package to use rules_js (#61623) 2025-05-23 15:14:00 -07:00