dependencies Legend  Declarations  Module  Bootstrap  Providers  Exports cluster_AntdCoreModule cluster_AntdCoreModule_declarations cluster_AntdCoreModule_exports DomReadyDirective DomReadyDirective AntdCoreModule AntdCoreModule DomReadyDirective->AntdCoreModule DomReadyDirective DomReadyDirective AntdCoreModule->DomReadyDirective

File

my-lib/core/core.module.ts

Declarations

import { Directive, OnInit, ElementRef, NgModule } from '@angular/core';

@Directive({ selector: '[domReady]' })
export class DomReadyDirective implements OnInit {
    constructor(
        public ele: ElementRef
    ) {
        console.log(new Date().getTime());
    }
    ngOnInit() {
        console.log(this.ele.nativeElement.target);
        console.log(new Date().getTime());
    }
}
@NgModule({
    imports: [],
    exports: [
        DomReadyDirective
    ],
    declarations: [
        DomReadyDirective
    ],
    providers: [],
})
export class AntdCoreModule { }

results matching ""

    No results matching ""