refactor: fix undecorated classes with angular features in repo (#36921)

A few instances of undecorated classes with Angular features
have been discovered in the framework repo. This commit fixes
those.

PR Close #36921
This commit is contained in:
Paul Gschwendtner
2020-05-05 16:47:14 +02:00
committed by Alex Rickabaugh
parent 0577bf0e3e
commit e17fe90aaa
6 changed files with 15 additions and 8 deletions

View File

@ -3,6 +3,7 @@ import {
AfterContentInit,
AfterViewChecked,
AfterViewInit,
Directive,
DoCheck,
OnChanges,
OnDestroy,
@ -15,7 +16,8 @@ import { LoggerService } from './logger.service';
let nextId = 1;
// #docregion ngOnInit
export class PeekABoo implements OnInit {
@Directive()
export class PeekABooDirective implements OnInit {
constructor(private logger: LoggerService) { }
// implement OnInit's `ngOnInit` method
@ -34,7 +36,7 @@ export class PeekABoo implements OnInit {
})
// Don't HAVE to mention the Lifecycle Hook interfaces
// unless we want typing and tool support.
export class PeekABooComponent extends PeekABoo implements
export class PeekABooComponent extends PeekABooDirective implements
OnChanges, OnInit, DoCheck,
AfterContentInit, AfterContentChecked,
AfterViewInit, AfterViewChecked,