app-routing.module.ts 924 B

1234567891011121314151617181920212223242526272829303132
  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: 'tab-mine',
  10. loadChildren: () => import('./tab-mine/tab-mine.module').then( m => m.TabMinePageModule)
  11. },
  12. {
  13. path: 'user',
  14. loadChildren: () => import('../modules/user/user.module').then(m => m.UserModule)
  15. },
  16. {
  17. path: 'contacts',
  18. loadChildren: () => import('../modules/contacts/contacts.module').then(m => m.ContactsModule)
  19. },
  20. {
  21. path: 'homepage',
  22. loadChildren: () => import('../modules/homepage/homepage.module').then(m => m.HomepageModule)
  23. }
  24. ];
  25. @NgModule({
  26. imports: [
  27. RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules })
  28. ],
  29. exports: [RouterModule]
  30. })
  31. export class AppRoutingModule {}