X-Git-Url: https://juplo.de/gitweb/?p=examples%2Fangular-tour-of-heroes;a=blobdiff_plain;f=src%2Fapp%2Fapp-routing.module.ts;h=b0354f5f5ec27f88b8e9d7097a137eacec3acde5;hp=807a865cb0d4fdd3ff850a745876708164c19f88;hb=2f6f2d86ff7765914cd9105069181ed1f1792f44;hpb=0666181cc32377d48501a42c465b08d3e660ab62 diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts index 807a865..b0354f5 100644 --- a/src/app/app-routing.module.ts +++ b/src/app/app-routing.module.ts @@ -1,10 +1,13 @@ import { NgModule } from '@angular/core'; import { RouterModule, Routes } from '@angular/router'; import { HeroesComponent } from './heroes/heroes.component'; +import { DashboardComponent } from './dashboard/dashboard.component'; const routes : Routes = [ - { path: 'heroes', component: HeroesComponent } + { path: '', redirectTo: 'dashboard', pathMatch: 'full'}, + { path: 'heroes', component: HeroesComponent }, + { path: 'dashboard', component: DashboardComponent } ];