src/app/core/ui/abstract-view/abstract-view.component.ts
Base class for wrapper components like RoutedViewComponent or DialogViewComponent
No results matching.
Properties |
constructor(injector: Injector, isDialog: boolean)
|
| componentInjector |
Type : Injector | undefined
|
| viewContext |
Type : ViewComponentContext
|
import { Injector } from "@angular/core";
import { ViewComponentContext } from "./view-component-context";
/**
* Base class for wrapper components like RoutedViewComponent or DialogViewComponent
*/
export abstract class AbstractViewComponent {
viewContext: ViewComponentContext;
componentInjector: Injector | undefined;
constructor(injector: Injector, isDialog: boolean) {
this.viewContext = new ViewComponentContext(isDialog);
this.componentInjector = Injector.create({
providers: [
{ provide: ViewComponentContext, useValue: this.viewContext },
],
parent: injector,
});
}
}