apps/codelab/src/app/components/external-link-directive/external-link-directive.directive.ts
import { Directive, Input, ElementRef } from '@angular/core';
@Directive({
// tslint:disable-next-line
selector: '[href]'
})
// TODO(meinou): Remove the second postfix
export class ExternalLinkDirectiveDirective {
constructor({ nativeElement }: ElementRef) {
nativeElement.target = '_blank';
}
}