1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';
import {CupboardComponent} from './components/cupboard/cupboard.component';
import {DashboardComponent} from './components/dashboard/dashboard.component';
import {LoginComponent} from './components/login/login.component';
import {HomePageComponent} from './components/home-page/home-page.component';
import {FundingBasketComponent} from './components/funding-basket/funding-basket.component';
import {NeedPageComponent} from './components/need-page/need-page.component';
const routes: Routes = [
{ path: '', component: HomePageComponent, title: "Home | JS" },
{ path: 'login', component: LoginComponent, title: "Login | JS" },
{ path: 'cupboard', component: CupboardComponent, title: "Cupboard | JS" },
{ path: 'dashboard', component: DashboardComponent, title: "Dashboard | JS" },
{ path: 'basket', component: FundingBasketComponent, title: "Basket | JS" },
{ path: 'need/:id', component: NeedPageComponent, title: "Need | JS" }
];
@NgModule({
imports: [RouterModule.forRoot(routes)],
exports: [RouterModule]
})
export class AppRoutingModule {
}
|