This repository was archived by the owner on Dec 4, 2017. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +5
-13
lines changed Expand file tree Collapse file tree 3 files changed +5
-13
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import { FormsModule } from '@angular/forms';
5
5
6
6
import { AppComponent } from './app.component' ;
7
7
8
+ import { HeroDetailComponent } from './hero-detail.component' ;
8
9
import { HeroesComponent } from './heroes.component' ;
9
10
10
11
import { HeroService } from './hero.service' ;
@@ -16,6 +17,7 @@ import { HeroService } from './hero.service';
16
17
] ,
17
18
declarations : [
18
19
AppComponent ,
20
+ HeroDetailComponent ,
19
21
HeroesComponent
20
22
] ,
21
23
providers : [
Original file line number Diff line number Diff line change @@ -9,9 +9,9 @@ import { AppComponent } from './app.component';
9
9
import { routing } from './app.routing' ;
10
10
// #enddocregion routing
11
11
12
+ import { HeroDetailComponent } from './hero-detail.component' ;
12
13
import { HeroesComponent } from './heroes.component' ;
13
14
import { DashboardComponent } from './dashboard.component' ;
14
- import { HeroDetailComponent } from './hero-detail.component' ;
15
15
16
16
import { HeroService } from './hero.service' ;
17
17
// #docregion routing
@@ -26,10 +26,10 @@ import { HeroService } from './hero.service';
26
26
// #docregion dashboard, hero-detail
27
27
declarations : [
28
28
AppComponent ,
29
+ HeroDetailComponent ,
29
30
HeroesComponent ,
30
- DashboardComponent ,
31
+ DashboardComponent
31
32
// #enddocregion dashboard
32
- HeroDetailComponent
33
33
// #docregion dashboard
34
34
] ,
35
35
// #enddocregion dashboard, hero-detail
Original file line number Diff line number Diff line change @@ -479,16 +479,6 @@ code-example(format='').
479
479
The colon (:) in the path indicates that `:id` is a placeholder to be filled with a specific hero `id`
480
480
when navigating to the `HeroDetailComponent`.
481
481
482
- .l-sub-section
483
- :marked
484
- Remember to import the hero detail component before creating this route.
485
-
486
- + ifDocsFor('ts|js' )
487
- :marked
488
- Add the `HeroDetailComponent` to our root NgModule's `declarations`.
489
-
490
- + makeExcerpt('app/app.module.ts' , 'hero-detail' )
491
-
492
482
:marked
493
483
We're finished with the application routes.
494
484
You can’t perform that action at this time.
0 commit comments