]>
Commit | Line | Data |
---|---|---|
df98563e | 1 | import { NgModule } from '@angular/core' |
ae5a3dd6 | 2 | import { RouterModule, Routes } from '@angular/router' |
a685e25c C |
3 | |
4 | import { PreloadSelectedModulesList } from './core' | |
693b1aba C |
5 | |
6 | const routes: Routes = [ | |
4b4f22fc C |
7 | { |
8 | path: 'admin', | |
9 | loadChildren: './+admin/admin.module#AdminModule' | |
10 | }, | |
11 | { | |
12 | path: 'my-account', | |
13 | loadChildren: './+my-account/my-account.module#MyAccountModule' | |
14 | }, | |
15 | { | |
16 | path: 'accounts', | |
17 | loadChildren: './+accounts/accounts.module#AccountsModule' | |
18 | }, | |
19 | { | |
20 | path: 'video-channels', | |
21 | loadChildren: './+video-channels/video-channels.module#VideoChannelsModule' | |
a51bad1a | 22 | }, |
78f912ed C |
23 | { |
24 | path: 'about', | |
25 | loadChildren: './+about/about.module#AboutModule' | |
26 | }, | |
a51bad1a C |
27 | { |
28 | path: '**', | |
29 | loadChildren: './+page-not-found/page-not-found.module#PageNotFoundModule' | |
4b4f22fc | 30 | } |
df98563e | 31 | ] |
693b1aba C |
32 | |
33 | @NgModule({ | |
04de542a C |
34 | imports: [ |
35 | RouterModule.forRoot(routes, { | |
36 | useHash: Boolean(history.pushState) === false, | |
a685e25c | 37 | preloadingStrategy: PreloadSelectedModulesList |
04de542a C |
38 | }) |
39 | ], | |
901637bb C |
40 | providers: [ |
41 | PreloadSelectedModulesList | |
42 | ], | |
693b1aba C |
43 | exports: [ RouterModule ] |
44 | }) | |
45 | export class AppRoutingModule {} |