projects
/
examples
/
angular-tutorial
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Cart-Component und zugehöriges Routing hinzugefügt
[examples/angular-tutorial]
/
src
/
app
/
app.module.ts
diff --git
a/src/app/app.module.ts
b/src/app/app.module.ts
index
d6559fb
..
9fa5aad
100644
(file)
--- a/
src/app/app.module.ts
+++ b/
src/app/app.module.ts
@@
-4,15
+4,26
@@
import { RouterModule } from '@angular/router';
import { AppComponent } from './app.component';
import { TopBarComponent } from './top-bar/top-bar.component';
import { AppComponent } from './app.component';
import { TopBarComponent } from './top-bar/top-bar.component';
+import { ProductListComponent } from './product-list/product-list.component';
+import { ProductDetailsComponent } from './product-details/product-details.component';
+import { ProductAlertsComponent } from './product-alerts/product-alerts.component';
+import { CartComponent } from './cart/cart.component';
@NgModule({
declarations: [
AppComponent,
@NgModule({
declarations: [
AppComponent,
- TopBarComponent
+ TopBarComponent,
+ ProductListComponent,
+ ProductDetailsComponent,
+ ProductAlertsComponent,
+ CartComponent
],
imports: [
BrowserModule,
RouterModule.forRoot([
],
imports: [
BrowserModule,
RouterModule.forRoot([
+ { path: '', component: ProductListComponent },
+ { path: 'products/:productId', component: ProductDetailsComponent },
+ { path: 'cart', component: CartComponent }
])
],
providers: [],
])
],
providers: [],