export function PageTrack ( pageName ) { return function ( constructor ) { const ngOnInit = constructor . prototype . ngOnInit ; constructor . prototype . ngOnInit = function ( ... args ) { ngOnInit && ngOnInit . apply ( this , args ) ; } ; const ngOnDestroy = constructor . prototype . ngOnDestroy ; constructor . prototype . ngOnDestroy = function ( ... args ) { ngOnDestroy && ngOnDestroy . apply ( this , args ) ; } ; } ; }