ngx-admin/src/app/app-routing.module.ts

21 lines
510 B
TypeScript
Raw Normal View History

2017-04-13 14:24:23 +03:00
import { ExtraOptions, RouterModule, Routes } from '@angular/router';
import { NgModule } from '@angular/core';
const routes: Routes = [
// {path: 'admin'}
{ path: 'pages', loadChildren: 'app/pages/pages.module#PagesModule' },
{ path: '', redirectTo: 'pages', pathMatch: 'full' },
{ path: '**', redirectTo: 'pages' },
2017-04-13 14:24:23 +03:00
];
const config: ExtraOptions = {
useHash: true,
2017-04-13 14:24:23 +03:00
};
@NgModule({
imports: [RouterModule.forRoot(routes, config)],
exports: [RouterModule],
2017-04-13 14:24:23 +03:00
})
export class AppRoutingModule {
}