Advertisement
Guest User

Untitled

a guest
Jun 12th, 2019
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. import { NgModule } from '@angular/core';
  2. import { RouterModule, Routes } from '@angular/router';
  3.  
  4. const routes: Routes = [
  5. { path: 'home', loadChildren: () => import('./home/home.module').then(m => m.HomeModule) },
  6. { path: 'user', loadChildren: () => import('./user/user.module').then(m => m.UserModule) },
  7. {
  8. path: '',
  9. pathMatch: 'full',
  10. redirectTo: 'home'
  11. }
  12.  
  13. ];
  14.  
  15. @NgModule({
  16. declarations: [],
  17. imports: [
  18. RouterModule.forRoot(routes, { useHash: true })
  19. ],
  20. exports: [RouterModule]
  21. })
  22. export class AppRoutingModule { }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement