2016-04-09 00:18:37 -04:00
|
|
|
// #docplaster
|
|
|
|
// #docregion
|
2016-06-26 13:13:44 -04:00
|
|
|
import { Component } from '@angular/core';
|
2016-04-09 00:18:37 -04:00
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'my-app',
|
|
|
|
|
|
|
|
template: `
|
|
|
|
<h1>{{title}}</h1>
|
|
|
|
<nav>
|
2016-08-09 12:38:25 -04:00
|
|
|
<a routerLink="/dashboard" routerLinkActive="active">Dashboard</a>
|
|
|
|
<a routerLink="/heroes" routerLinkActive="active">Heroes</a>
|
2016-04-09 00:18:37 -04:00
|
|
|
</nav>
|
|
|
|
<router-outlet></router-outlet>
|
|
|
|
`,
|
2016-08-09 12:38:25 -04:00
|
|
|
styleUrls: ['app/app.component.css']
|
2016-04-09 00:18:37 -04:00
|
|
|
})
|
|
|
|
export class AppComponent {
|
|
|
|
title = 'Tour of Heroes';
|
|
|
|
}
|