mirror of
https://github.com/akveo/ngx-admin.git
synced 2025-09-21 21:40:49 +02:00
28 lines
581 B
TypeScript
28 lines
581 B
TypeScript
import { ExtraOptions, RouterModule, Routes } from '@angular/router';
|
|
import { NgModule } from '@angular/core';
|
|
|
|
const routes: Routes = [
|
|
{
|
|
path: '',
|
|
loadChildren: () => import('./pages/pages.module')
|
|
.then(m => m.PagesModule),
|
|
},
|
|
{
|
|
path: '**',
|
|
redirectTo: '',
|
|
},
|
|
];
|
|
|
|
const config: ExtraOptions = {
|
|
useHash: false,
|
|
anchorScrolling: 'enabled',
|
|
onSameUrlNavigation: 'reload',
|
|
scrollPositionRestoration: 'enabled',
|
|
};
|
|
|
|
@NgModule({
|
|
imports: [RouterModule.forRoot(routes, config)],
|
|
exports: [RouterModule],
|
|
})
|
|
export class AppRoutingModule {
|
|
}
|