|
1 | 1 | import { RouterConfig } from '@angular/router';
|
2 |
| - |
3 | 2 | import { HomeComponent } from './home/home.component';
|
4 | 3 |
|
5 |
| -import { IterationOneComponent } from './book-monkey/iteration-1/iteration-1.component'; |
6 |
| -import { AppComponent as BookDetailsApp } from './book-monkey/iteration-1/book-details/index'; |
7 |
| -import { AppComponent as BookListApp } from './book-monkey/iteration-1/book-list/index'; |
8 |
| -import { AppComponent as BookListRefactoredApp } from './book-monkey/iteration-1/book-list-refactored/index'; |
9 |
| - |
10 |
| -import { IterationTwoComponent } from './book-monkey/iteration-2/iteration-2.component'; |
11 |
| -import { AppComponent as diApp } from './book-monkey/iteration-2/di/index'; |
12 |
| -import { AppComponent as NavigationApp, AppRoutes as NavigationAppRoutes } from './book-monkey/iteration-2/navigation/index'; |
13 |
| - |
14 |
| -import { IterationThreeComponent } from './book-monkey/iteration-3/iteration-3.component'; |
15 |
| -import { AppComponent as FormsApp, AppRoutes as FormsAppRoutes } from './book-monkey/iteration-3/forms/index'; |
16 |
| -import { AppComponent as ValidationApp, AppRoutes as ValidationAppRoutes } from './book-monkey/iteration-3/validation/index'; |
17 |
| - |
18 |
| -import { IterationFourComponent } from './book-monkey/iteration-4/iteration-4.component'; |
19 |
| -import { AppComponent as HttpApp, AppRoutes as HttpAppRoutes } from './book-monkey/iteration-4/http/index'; |
20 |
| - |
21 |
| -import { IterationFiveComponent } from './book-monkey/iteration-5/iteration-5.component'; |
22 |
| -import { AppComponent as PipesApp, AppRoutes as PipesAppRoutes } from './book-monkey/iteration-5/pipes/index'; |
23 |
| -import { AppComponent as DirectivesApp, AppRoutes as DirectivesAppRoutes } from './book-monkey/iteration-5/directives/index'; |
24 |
| - |
25 |
| -export const AppRoutes: RouterConfig = [ |
| 4 | +export const IterationRoutes: RouterConfig = [ |
26 | 5 | {
|
27 | 6 | path: '',
|
28 | 7 | component: HomeComponent
|
29 | 8 | },
|
30 | 9 | {
|
31 | 10 | path: 'iteration-1',
|
32 |
| - component: IterationOneComponent, |
33 |
| - children: [ |
34 |
| - { |
35 |
| - path: '', |
36 |
| - redirectTo: 'book-list' |
37 |
| - }, |
38 |
| - { |
39 |
| - path: 'book-list', |
40 |
| - component: BookListApp, |
41 |
| - }, |
42 |
| - { |
43 |
| - path: 'book-list-refactored', |
44 |
| - component: BookListRefactoredApp |
45 |
| - }, |
46 |
| - { |
47 |
| - path: 'book-details', |
48 |
| - component: BookDetailsApp |
49 |
| - } |
50 |
| - ] |
51 |
| - }, |
| 11 | + loadChildren: 'app/book-monkey/iteration-1/iteration-1.module#IterationOneModule' |
| 12 | + } |
| 13 | + /*, |
52 | 14 | {
|
53 | 15 | path: 'iteration-2',
|
54 |
| - component: IterationTwoComponent, |
55 |
| - children: [ |
56 |
| - { |
57 |
| - path: '', |
58 |
| - redirectTo: 'dependency-injection' |
59 |
| - }, |
60 |
| - { |
61 |
| - path: 'dependency-injection', |
62 |
| - component: diApp, |
63 |
| - }, |
64 |
| - { |
65 |
| - path: 'navigation', |
66 |
| - component: NavigationApp, |
67 |
| - children: [ ...NavigationAppRoutes ] |
68 |
| - } |
69 |
| - ] |
| 16 | + loadChildren: './book-monkey/iteration-2/iteration-2.module#IterationTwoModule' |
70 | 17 | },
|
71 | 18 | {
|
72 | 19 | path: 'iteration-3',
|
73 |
| - component: IterationThreeComponent, |
74 |
| - children: [ |
75 |
| - { |
76 |
| - path: '', |
77 |
| - redirectTo: 'form' |
78 |
| - }, |
79 |
| - { |
80 |
| - path: 'form', |
81 |
| - component: FormsApp, |
82 |
| - children: [ ...FormsAppRoutes ], |
83 |
| - }, |
84 |
| - { |
85 |
| - path: 'validation', |
86 |
| - component: ValidationApp, |
87 |
| - children: [ ...ValidationAppRoutes ] |
88 |
| - } |
89 |
| - ] |
| 20 | + loadChildren: './book-monkey/iteration-3/iteration-3.module#IterationThreeModule' |
90 | 21 | },
|
91 | 22 | {
|
92 | 23 | path: 'iteration-4',
|
93 |
| - component: IterationFourComponent, |
94 |
| - children: [ |
95 |
| - { |
96 |
| - path: '', |
97 |
| - redirectTo: 'http' |
98 |
| - }, |
99 |
| - { |
100 |
| - path: 'http', |
101 |
| - component: HttpApp, |
102 |
| - children: [ ...HttpAppRoutes ], |
103 |
| - } |
104 |
| - ] |
| 24 | + loadChildren: './book-monkey/iteration-4/iteration-4.module#IterationFourModule' |
105 | 25 | },
|
106 | 26 | {
|
107 | 27 | path: 'iteration-5',
|
108 |
| - component: IterationFiveComponent, |
109 |
| - children: [ |
110 |
| - { |
111 |
| - path: '', |
112 |
| - redirectTo: 'pipes' |
113 |
| - }, |
114 |
| - { |
115 |
| - path: 'pipes', |
116 |
| - component: PipesApp, |
117 |
| - children: [ ...PipesAppRoutes ], |
118 |
| - }, |
119 |
| - { |
120 |
| - path: 'directives', |
121 |
| - component: DirectivesApp, |
122 |
| - children: [ ...DirectivesAppRoutes ] |
123 |
| - } |
124 |
| - ] |
125 |
| - } |
| 28 | + loadChildren: './book-monkey/iteration-5/iteration-5.module#IterationFiveModule' |
| 29 | + }*/ |
126 | 30 | ];
|
127 | 31 |
|
0 commit comments