app-routing.module.ts 778 B

1234567891011121314151617181920212223242526272829
  1. import { NgModule } from '@angular/core';
  2. import { PreloadAllModules, RouterModule, Routes } from '@angular/router';
  3. const routes: Routes = [
  4. {
  5. path: '',
  6. loadChildren: () => import('./tabs/tabs.module').then(m => m.TabsPageModule)
  7. },
  8. {
  9. path: 'calendar',
  10. loadChildren: () => import('./calendar/calendar.module').then( m => m.CalendarPageModule)
  11. },
  12. {
  13. path: 'user',
  14. loadChildren: () => import('../modules/user/user.module').then(m => m.UserModule)
  15. },
  16. {
  17. path: "tree",
  18. loadChildren: () => import('../modules/tab/tree/tree.module').then(m => m.TreePageModule)
  19. },
  20. ];
  21. @NgModule({
  22. imports: [
  23. RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules })
  24. ],
  25. exports: [RouterModule]
  26. })
  27. export class AppRoutingModule {}