diff --git a/projects/elements/testing/lazy-element-dynamic-testing.directive.ts b/projects/elements/testing/lazy-element-dynamic-testing.directive.ts index 4f7b239..9de6d4f 100644 --- a/projects/elements/testing/lazy-element-dynamic-testing.directive.ts +++ b/projects/elements/testing/lazy-element-dynamic-testing.directive.ts @@ -1,5 +1,6 @@ import { Directive, + inject, OnInit, TemplateRef, ViewContainerRef, @@ -9,10 +10,8 @@ import { selector: '[axLazyElementDynamic]', }) export class LazyElementDynamicTestingDirective implements OnInit { - constructor( - private vcr: ViewContainerRef, - private template: TemplateRef - ) {} + private readonly vcr = inject(ViewContainerRef); + private readonly template = inject(TemplateRef); ngOnInit() { this.vcr.createEmbeddedView(this.template); diff --git a/projects/elements/testing/lazy-element-testing.directive.ts b/projects/elements/testing/lazy-element-testing.directive.ts index 7b1ba7c..d977022 100644 --- a/projects/elements/testing/lazy-element-testing.directive.ts +++ b/projects/elements/testing/lazy-element-testing.directive.ts @@ -1,5 +1,6 @@ import { Directive, + inject, OnInit, TemplateRef, ViewContainerRef, @@ -9,10 +10,8 @@ import { selector: '[axLazyElement]', }) export class LazyElementTestingDirective implements OnInit { - constructor( - private vcr: ViewContainerRef, - private template: TemplateRef - ) {} + private readonly vcr = inject(ViewContainerRef); + private readonly template = inject(TemplateRef); ngOnInit() { this.vcr.createEmbeddedView(this.template);