Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { Component, Input, AfterViewInit } from '@angular/core';
- @Component({
- selector: 'hello',
- template: `<h1>Hello {{name}}!</h1>`,
- styles: [`h1 { font-family: Lato; }`]
- })
- export class HelloComponent implements AfterViewInit{
- @Input() name: string;
- ngAfterViewInit() {
- this.name = 'foo';
- }
- }
Add Comment
Please, Sign In to add comment