Blame view

src/app/pages/pages.routing.ts 991 Bytes
05b0b5d8   Yarik   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
  import { Routes, RouterModule }  from '@angular/router';
  import { Pages } from './pages.component';
  import { ModuleWithProviders } from '@angular/core';
  // noinspection TypeScriptValidateTypes
  
  // export function loadChildren(path) { return System.import(path); };
  
  export const routes: Routes = [
    {
      path: 'login',
      loadChildren: 'app/pages/login/login.module#LoginModule'
    },
    {
      path: 'register',
      loadChildren: 'app/pages/register/register.module#RegisterModule'
    },
    {
      path: 'pages',
      component: Pages,
      children: [
        { path: '', redirectTo: 'dashboard', pathMatch: 'full' },
        { path: 'dashboard', loadChildren: 'app/pages/dashboard/dashboard.module#DashboardModule' },
        { path: 'tables', loadChildren: 'app/pages/tables/tables.module#TablesModule' },
        { path: 'statements', loadChildren: 'app/pages/statements/statements.module#StatementsModule' },
      ]
    }
  ];
  
  export const routing: ModuleWithProviders = RouterModule.forChild(routes);