This repository was archived by the owner on Dec 4, 2017. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +12
-19
lines changed Expand file tree Collapse file tree 4 files changed +12
-19
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ import { BrowserModule } from '@angular/platform-browser';
4
4
import { FormsModule } from '@angular/forms' ;
5
5
6
6
import { AppComponent } from './app.component' ;
7
-
7
+ import { HeroDetailComponent } from './hero-detail.component' ;
8
8
import { HeroesComponent } from './heroes.component' ;
9
9
10
10
import { HeroService } from './hero.service' ;
@@ -16,6 +16,7 @@ import { HeroService } from './hero.service';
16
16
] ,
17
17
declarations : [
18
18
AppComponent ,
19
+ HeroDetailComponent ,
19
20
HeroesComponent
20
21
] ,
21
22
providers : [
Original file line number Diff line number Diff line change @@ -8,10 +8,9 @@ import { AppComponent } from './app.component';
8
8
// #docregion routing
9
9
import { routing } from './app.routing' ;
10
10
// #enddocregion routing
11
-
11
+ import { HeroDetailComponent } from './hero-detail.component' ;
12
12
import { HeroesComponent } from './heroes.component' ;
13
13
import { DashboardComponent } from './dashboard.component' ;
14
- import { HeroDetailComponent } from './hero-detail.component' ;
15
14
16
15
import { HeroService } from './hero.service' ;
17
16
// #docregion routing
@@ -26,11 +25,9 @@ import { HeroService } from './hero.service';
26
25
// #docregion dashboard, hero-detail
27
26
declarations : [
28
27
AppComponent ,
28
+ HeroDetailComponent ,
29
29
HeroesComponent ,
30
- DashboardComponent ,
31
- // #enddocregion dashboard
32
- HeroDetailComponent
33
- // #docregion dashboard
30
+ DashboardComponent
34
31
] ,
35
32
// #enddocregion dashboard, hero-detail
36
33
providers : [
Original file line number Diff line number Diff line change @@ -16,9 +16,9 @@ import { InMemoryDataService } from './in-memory-data.service';
16
16
import { AppComponent } from './app.component' ;
17
17
import { routing } from './app.routing' ;
18
18
19
+ import { HeroDetailComponent } from './hero-detail.component' ;
19
20
import { HeroesComponent } from './heroes.component' ;
20
21
import { DashboardComponent } from './dashboard.component' ;
21
- import { HeroDetailComponent } from './hero-detail.component' ;
22
22
import { HeroService } from './hero.service' ;
23
23
// #enddocregion v1, v2
24
24
// #docregion search
@@ -36,9 +36,9 @@ import { HeroSearchComponent } from './hero-search.component';
36
36
// #docregion search
37
37
declarations : [
38
38
AppComponent ,
39
+ HeroDetailComponent ,
39
40
HeroesComponent ,
40
41
DashboardComponent ,
41
- HeroDetailComponent ,
42
42
// #enddocregion v1, v2
43
43
HeroSearchComponent
44
44
// #docregion v1, v2
Original file line number Diff line number Diff line change @@ -478,16 +478,11 @@ code-example(format='').
478
478
:marked
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
-
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' )
481
+
482
+ + ifDocsFor('dart' )
483
+ .l-sub-section
484
+ :marked
485
+ Remember to import the hero detail component before creating this route.
491
486
492
487
:marked
493
488
We're finished with the application routes.
You can’t perform that action at this time.
0 commit comments