Skip to content

Latest commit

 

History

History
47 lines (26 loc) · 2.29 KB

File metadata and controls

47 lines (26 loc) · 2.29 KB
graph LR
    Injector["Injector"]
    Provider["Provider"]
    _Injectable_decorator["@Injectable() decorator"]
    Injector -- "uses" --> Provider
    Injector -- "reads declarations from" --> _Injectable_decorator
    Provider -- "configures" --> Injector
    _Injectable_decorator -- "marks classes for" --> Injector
Loading

CodeBoardingDemoContact

Details

The Dependency Injection System subsystem in Angular is responsible for managing the creation, resolution, and lifecycle of injectable instances (services, components, directives). It acts as the core mechanism for providing dependencies throughout the application, promoting modularity and testability.

Injector

The core runtime mechanism responsible for resolving and providing dependencies. It maintains a collection of providers and instantiates dependencies as needed.

Related Classes/Methods:

Provider

A configuration object that instructs the Injector on how to obtain a value for a specific dependency token. Providers define the "recipe" for creating or providing an instance.

Related Classes/Methods:

@Injectable() decorator

A decorator that marks a class as a service that can be injected by the Angular DI system. It can also be used to configure providers for the decorated class.

Related Classes/Methods: