diff --git a/src/addons/badges/badge-lazy.module.ts b/src/addons/badges/badge-lazy.module.ts index e59049c66..172a3fc60 100644 --- a/src/addons/badges/badge-lazy.module.ts +++ b/src/addons/badges/badge-lazy.module.ts @@ -30,4 +30,4 @@ const routes: Routes = [ RouterModule.forChild(routes), ], }) -export class AddonBadgeLazyModule {} +export default class AddonBadgeLazyModule {} diff --git a/src/addons/badges/badgeclass-lazy.module.ts b/src/addons/badges/badgeclass-lazy.module.ts index c8d0901f3..51a2e38f2 100644 --- a/src/addons/badges/badgeclass-lazy.module.ts +++ b/src/addons/badges/badgeclass-lazy.module.ts @@ -33,4 +33,4 @@ const routes: Routes = [ AddonBadgesBadgeClassPage, ], }) -export class AddonBadgeClassLazyModule {} +export default class AddonBadgeClassLazyModule {} diff --git a/src/addons/badges/badges-lazy.module.ts b/src/addons/badges/badges-lazy.module.ts index db153560e..e2b44df54 100644 --- a/src/addons/badges/badges-lazy.module.ts +++ b/src/addons/badges/badges-lazy.module.ts @@ -63,4 +63,4 @@ const routes: Routes = [ AddonBadgesUserBadgesPage, ], }) -export class AddonBadgesLazyModule {} +export default class AddonBadgesLazyModule {} diff --git a/src/addons/badges/badges.module.ts b/src/addons/badges/badges.module.ts index 179319ef6..2bcc796f2 100644 --- a/src/addons/badges/badges.module.ts +++ b/src/addons/badges/badges.module.ts @@ -43,15 +43,15 @@ export async function getBadgesServices(): Promise[]> { const mainMenuRoutes: Routes = [ { path: 'badge', - loadChildren: () => import('./badge-lazy.module').then(m => m.AddonBadgeLazyModule), + loadChildren: () => import('./badge-lazy.module'), }, { path: 'badges', - loadChildren: () => import('./badges-lazy.module').then(m => m.AddonBadgesLazyModule), + loadChildren: () => import('./badges-lazy.module'), }, { path: 'badgeclass', - loadChildren: () => import('./badgeclass-lazy.module').then(m => m.AddonBadgeClassLazyModule), + loadChildren: () => import('./badgeclass-lazy.module'), }, ]; diff --git a/src/addons/blog/blog-lazy.module.ts b/src/addons/blog/blog-lazy.module.ts index 1dcdf88c8..ad4059eb6 100644 --- a/src/addons/blog/blog-lazy.module.ts +++ b/src/addons/blog/blog-lazy.module.ts @@ -42,7 +42,7 @@ import { canLeaveGuard } from '@guards/can-leave'; }, { path: 'edit/:id', - loadComponent: () => import('./pages/edit-entry/edit-entry').then(c => c.AddonBlogEditEntryPage), + loadComponent: () => import('./pages/edit-entry/edit-entry'), canDeactivate: [canLeaveGuard], }, ...buildTabMainRoutes(injector, { @@ -71,4 +71,4 @@ import { canLeaveGuard } from '@guards/can-leave'; }, ], }) -export class AddonBlogLazyModule {} +export default class AddonBlogLazyModule {} diff --git a/src/addons/blog/blog.module.ts b/src/addons/blog/blog.module.ts index 06959bdf3..7e15a9af0 100644 --- a/src/addons/blog/blog.module.ts +++ b/src/addons/blog/blog.module.ts @@ -37,7 +37,7 @@ import { AddonBlogSyncCronHandler } from './services/handlers/sync-cron'; const routes: Routes = [ { path: ADDON_BLOG_MAINMENU_PAGE_NAME, - loadChildren: () => import('@addons/blog/blog-lazy.module').then(m => m.AddonBlogLazyModule), + loadChildren: () => import('@addons/blog/blog-lazy.module'), }, ]; diff --git a/src/addons/blog/pages/edit-entry/edit-entry.ts b/src/addons/blog/pages/edit-entry/edit-entry.ts index 9eaba2f33..462df4610 100644 --- a/src/addons/blog/pages/edit-entry/edit-entry.ts +++ b/src/addons/blog/pages/edit-entry/edit-entry.ts @@ -59,7 +59,7 @@ import { CoreTimeUtils } from '@services/utils/time'; CoreTagComponentsModule, ], }) -export class AddonBlogEditEntryPage implements CanLeave, OnInit, OnDestroy { +export default class AddonBlogEditEntryPage implements CanLeave, OnInit, OnDestroy { @ViewChild('editEntryForm') formElement!: ElementRef; diff --git a/src/addons/calendar/calendar-lazy.module.ts b/src/addons/calendar/calendar-lazy.module.ts index f423766d3..d228e4b70 100644 --- a/src/addons/calendar/calendar-lazy.module.ts +++ b/src/addons/calendar/calendar-lazy.module.ts @@ -86,4 +86,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class AddonCalendarLazyModule {} +export default class AddonCalendarLazyModule {} diff --git a/src/addons/calendar/calendar.module.ts b/src/addons/calendar/calendar.module.ts index f57cfbc76..933c3ed40 100644 --- a/src/addons/calendar/calendar.module.ts +++ b/src/addons/calendar/calendar.module.ts @@ -52,7 +52,7 @@ export async function getCalendarServices(): Promise[]> { const mainMenuChildrenRoutes: Routes = [ { path: AddonCalendarMainMenuHandlerService.PAGE_NAME, - loadChildren: () => import('./calendar-lazy.module').then(m => m.AddonCalendarLazyModule), + loadChildren: () => import('./calendar-lazy.module'), }, ]; diff --git a/src/addons/competency/competency-course-contents-lazy.module.ts b/src/addons/competency/competency-course-contents-lazy.module.ts index f132f614b..bee7bb5cf 100644 --- a/src/addons/competency/competency-course-contents-lazy.module.ts +++ b/src/addons/competency/competency-course-contents-lazy.module.ts @@ -31,4 +31,4 @@ const routes: Routes = [ AddonCompetencyCourseCompetenciesPageModule, ], }) -export class AddonCompetencyCourseContentsLazyModule {} +export default class AddonCompetencyCourseContentsLazyModule {} diff --git a/src/addons/competency/competency-course-details-lazy.module.ts b/src/addons/competency/competency-course-details-lazy.module.ts index 6d0530ae4..074d4dbb0 100644 --- a/src/addons/competency/competency-course-details-lazy.module.ts +++ b/src/addons/competency/competency-course-details-lazy.module.ts @@ -69,4 +69,4 @@ const routes: Routes = [ AddonCompetencyCompetencySummaryPageModule, ], }) -export class AddonCompetencyCourseDetailsLazyModule {} +export default class AddonCompetencyCourseDetailsLazyModule {} diff --git a/src/addons/competency/competency-learning-plans-lazy.module.ts b/src/addons/competency/competency-learning-plans-lazy.module.ts index bf093ed31..dbdcb244c 100644 --- a/src/addons/competency/competency-learning-plans-lazy.module.ts +++ b/src/addons/competency/competency-learning-plans-lazy.module.ts @@ -89,4 +89,4 @@ const routes: Routes = [ AddonCompetencyPlanListPage, ], }) -export class AddonCompetencyLearningPlansLazyModule {} +export default class AddonCompetencyLearningPlansLazyModule {} diff --git a/src/addons/competency/competency.module.ts b/src/addons/competency/competency.module.ts index aa4185579..8daa6170b 100644 --- a/src/addons/competency/competency.module.ts +++ b/src/addons/competency/competency.module.ts @@ -49,22 +49,22 @@ export async function getCompetencyServices(): Promise[]> { const mainMenuChildrenRoutes: Routes = [ { path: ADDON_COMPETENCY_LEARNING_PLANS_PAGE, - loadChildren: () => import('./competency-learning-plans-lazy.module').then(m => m.AddonCompetencyLearningPlansLazyModule), + loadChildren: () => import('./competency-learning-plans-lazy.module'), }, { path: `${COURSE_PAGE_NAME}/:courseId/${ADDON_COMPETENCY_COMPETENCIES_PAGE}`, - loadChildren: () => import('./competency-course-details-lazy.module').then(m => m.AddonCompetencyCourseDetailsLazyModule), + loadChildren: () => import('./competency-course-details-lazy.module'), }, { path: `${COURSE_PAGE_NAME}/:courseId/${PARTICIPANTS_PAGE_NAME}/:userId/${ADDON_COMPETENCY_COMPETENCIES_PAGE}`, - loadChildren: () => import('./competency-course-details-lazy.module').then(m => m.AddonCompetencyCourseDetailsLazyModule), + loadChildren: () => import('./competency-course-details-lazy.module'), }, ]; const courseIndexRoutes: Routes = [ { path: ADDON_COMPETENCY_COMPETENCIES_PAGE, - loadChildren: () => import('./competency-course-contents-lazy.module').then(m => m.AddonCompetencyCourseContentsLazyModule), + loadChildren: () => import('./competency-course-contents-lazy.module'), }, ]; diff --git a/src/addons/coursecompletion/coursecompletion-lazy.module.ts b/src/addons/coursecompletion/coursecompletion-lazy.module.ts index 2cf6534f8..766ec57ac 100644 --- a/src/addons/coursecompletion/coursecompletion-lazy.module.ts +++ b/src/addons/coursecompletion/coursecompletion-lazy.module.ts @@ -37,4 +37,4 @@ const routes: Routes = [ AddonCourseCompletionReportPage, ], }) -export class AddonCourseCompletionLazyModule {} +export default class AddonCourseCompletionLazyModule {} diff --git a/src/addons/coursecompletion/coursecompletion.module.ts b/src/addons/coursecompletion/coursecompletion.module.ts index 5dca1d450..687382520 100644 --- a/src/addons/coursecompletion/coursecompletion.module.ts +++ b/src/addons/coursecompletion/coursecompletion.module.ts @@ -39,7 +39,7 @@ export async function getCourseCompletionServices(): Promise[]> { const routes: Routes = [ { path: 'coursecompletion', - loadChildren: () => import('./coursecompletion-lazy.module').then(m => m.AddonCourseCompletionLazyModule), + loadChildren: () => import('./coursecompletion-lazy.module'), }, ]; diff --git a/src/addons/messages/messages-lazy.module.ts b/src/addons/messages/messages-lazy.module.ts index e6ec40442..fd571c34e 100644 --- a/src/addons/messages/messages-lazy.module.ts +++ b/src/addons/messages/messages-lazy.module.ts @@ -117,7 +117,7 @@ function buildRoutes(injector: Injector): Routes { ...discussionRoutes, { path: 'message-settings', - loadChildren: () => import('./messages-settings-lazy.module').then(m => m.AddonMessagesSettingsLazyModule), + loadChildren: () => import('./messages-settings-lazy.module'), }, ...buildTabMainRoutes(injector, { canActivate: [messagesIndexGuard], @@ -148,4 +148,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class AddonMessagesLazyModule {} +export default class AddonMessagesLazyModule {} diff --git a/src/addons/messages/messages-settings-lazy.module.ts b/src/addons/messages/messages-settings-lazy.module.ts index dbfc1d4da..15f93258b 100644 --- a/src/addons/messages/messages-settings-lazy.module.ts +++ b/src/addons/messages/messages-settings-lazy.module.ts @@ -34,4 +34,4 @@ const routes: Routes = [ AddonMessagesSettingsPage, ], }) -export class AddonMessagesSettingsLazyModule {} +export default class AddonMessagesSettingsLazyModule {} diff --git a/src/addons/messages/messages.module.ts b/src/addons/messages/messages.module.ts index 88ee85b75..5f2bfa183 100644 --- a/src/addons/messages/messages.module.ts +++ b/src/addons/messages/messages.module.ts @@ -58,13 +58,13 @@ export async function getMessagesServices(): Promise[]> { const mainMenuChildrenRoutes: Routes = [ { path: AddonMessagesMainMenuHandlerService.PAGE_NAME, - loadChildren: () => import('./messages-lazy.module').then(m => m.AddonMessagesLazyModule), + loadChildren: () => import('./messages-lazy.module'), }, ]; const preferencesRoutes: Routes = [ { path: AddonMessagesSettingsHandlerService.PAGE_NAME, - loadChildren: () => import('./messages-settings-lazy.module').then(m => m.AddonMessagesSettingsLazyModule), + loadChildren: () => import('./messages-settings-lazy.module'), }, ]; diff --git a/src/addons/notes/notes-lazy.module.ts b/src/addons/notes/notes-lazy.module.ts index 49997cb2e..fa97c950b 100644 --- a/src/addons/notes/notes-lazy.module.ts +++ b/src/addons/notes/notes-lazy.module.ts @@ -37,4 +37,4 @@ const routes: Routes = [ AddonNotesListPage, ], }) -export class AddonNotesLazyModule {} +export default class AddonNotesLazyModule {} diff --git a/src/addons/notes/notes.module.ts b/src/addons/notes/notes.module.ts index 3791c309e..655e4dc85 100644 --- a/src/addons/notes/notes.module.ts +++ b/src/addons/notes/notes.module.ts @@ -45,7 +45,7 @@ export async function getNotesServices(): Promise[]> { const routes: Routes = [ { path: 'notes', - loadChildren: () => import('@addons/notes/notes-lazy.module').then(m => m.AddonNotesLazyModule), + loadChildren: () => import('@addons/notes/notes-lazy.module'), }, ]; diff --git a/src/addons/notifications/notifications-lazy.module.ts b/src/addons/notifications/notifications-lazy.module.ts index fddc7ecf5..28ad32bdf 100644 --- a/src/addons/notifications/notifications-lazy.module.ts +++ b/src/addons/notifications/notifications-lazy.module.ts @@ -78,4 +78,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class AddonNotificationsLazyModule {} +export default class AddonNotificationsLazyModule {} diff --git a/src/addons/notifications/notifications-settings-lazy.module.ts b/src/addons/notifications/notifications-settings-lazy.module.ts index 83d2cd48f..e87cc5255 100644 --- a/src/addons/notifications/notifications-settings-lazy.module.ts +++ b/src/addons/notifications/notifications-settings-lazy.module.ts @@ -34,4 +34,4 @@ const routes: Routes = [ AddonNotificationsSettingsPage, ], }) -export class AddonNotificationsSettingsLazyModule {} +export default class AddonNotificationsSettingsLazyModule {} diff --git a/src/addons/notifications/notifications.module.ts b/src/addons/notifications/notifications.module.ts index 855191c7e..202bc62f4 100644 --- a/src/addons/notifications/notifications.module.ts +++ b/src/addons/notifications/notifications.module.ts @@ -48,13 +48,13 @@ export async function getNotificationsServices(): Promise[]> { const routes: Routes = [ { path: AddonNotificationsMainMenuHandlerService.PAGE_NAME, - loadChildren: () => import('./notifications-lazy.module').then(m => m.AddonNotificationsLazyModule), + loadChildren: () => import('./notifications-lazy.module'), }, ]; const preferencesRoutes: Routes = [ { path: AddonNotificationsSettingsHandlerService.PAGE_NAME, - loadChildren: () => import('./notifications-settings-lazy.module').then(m => m.AddonNotificationsSettingsLazyModule), + loadChildren: () => import('./notifications-settings-lazy.module'), }, ]; diff --git a/src/addons/privatefiles/privatefiles-lazy.module.ts b/src/addons/privatefiles/privatefiles-lazy.module.ts index 8677298e3..a0468983d 100644 --- a/src/addons/privatefiles/privatefiles-lazy.module.ts +++ b/src/addons/privatefiles/privatefiles-lazy.module.ts @@ -60,4 +60,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class AddonPrivateFilesLazyModule {} +export default class AddonPrivateFilesLazyModule {} diff --git a/src/addons/privatefiles/privatefiles.module.ts b/src/addons/privatefiles/privatefiles.module.ts index 2bdaa95ca..f4ed51220 100644 --- a/src/addons/privatefiles/privatefiles.module.ts +++ b/src/addons/privatefiles/privatefiles.module.ts @@ -38,7 +38,7 @@ export async function getPrivateFilesServices(): Promise[]> { const routes: Routes = [ { path: AddonPrivateFilesUserHandlerService.PAGE_NAME, - loadChildren: () => import('@addons/privatefiles/privatefiles-lazy.module').then(m => m.AddonPrivateFilesLazyModule), + loadChildren: () => import('@addons/privatefiles/privatefiles-lazy.module'), }, ]; diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts index d4b603e63..53704f588 100644 --- a/src/app/app-routing.module.ts +++ b/src/app/app-routing.module.ts @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -import { InjectionToken, Injector, ModuleWithProviders, NgModule, Type } from '@angular/core'; +import { InjectionToken, Injector, ModuleWithProviders, NgModule, NgModuleFactory, Type } from '@angular/core'; import { RouterModule, Route, @@ -22,7 +22,9 @@ import { UrlMatchResult, UrlSegment, UrlSegmentGroup, + DefaultExport, } from '@angular/router'; +import { Observable } from 'rxjs'; const modulesRoutes: WeakMap, ModuleRoutes> = new WeakMap(); @@ -97,10 +99,18 @@ function buildConditionalUrlMatcher(pathOrMatcher: string | UrlMatcher, conditio } /** - * Type to declare lazy route modules. + * Type to declare lazy route modules. Extracted from Angular's LoadChildrenCallback type. */ // eslint-disable-next-line @typescript-eslint/no-explicit-any -export type LazyRoutesModule = Type; +export type LazyRoutesModule = Type | + NgModuleFactory | // eslint-disable-line deprecation/deprecation, @typescript-eslint/no-explicit-any + Routes | + Observable | // eslint-disable-line @typescript-eslint/no-explicit-any + Routes | + DefaultExport> | // eslint-disable-line @typescript-eslint/no-explicit-any + DefaultExport> | + // eslint-disable-next-line deprecation/deprecation, @typescript-eslint/no-explicit-any + Promise | Type | Routes | DefaultExport> |DefaultExport>; /** * Build url matcher using a regular expression. diff --git a/src/core/features/comments/comments-lazy.module.ts b/src/core/features/comments/comments-lazy.module.ts index efce272c0..36e600004 100644 --- a/src/core/features/comments/comments-lazy.module.ts +++ b/src/core/features/comments/comments-lazy.module.ts @@ -33,4 +33,4 @@ const routes: Routes = [ CoreCommentsViewerPage, ], }) -export class CoreCommentsLazyModule {} +export default class CoreCommentsLazyModule {} diff --git a/src/core/features/comments/comments.module.ts b/src/core/features/comments/comments.module.ts index 7d2c29f13..279fa33af 100644 --- a/src/core/features/comments/comments.module.ts +++ b/src/core/features/comments/comments.module.ts @@ -42,7 +42,7 @@ export async function getCommentsServices(): Promise[]> { const routes: Routes = [ { path: 'comments', - loadChildren: () => import('@features/comments/comments-lazy.module').then(m => m.CoreCommentsLazyModule), + loadChildren: () => import('@features/comments/comments-lazy.module'), }, ]; diff --git a/src/core/features/course/course-contents-lazy.module.ts b/src/core/features/course/course-contents-lazy.module.ts index 0d1d84b74..d64416bda 100644 --- a/src/core/features/course/course-contents-lazy.module.ts +++ b/src/core/features/course/course-contents-lazy.module.ts @@ -53,4 +53,4 @@ function buildRoutes(injector: Injector): Routes { CoreCourseContentsPage, ], }) -export class CoreCourseContentsLazyModule {} +export default class CoreCourseContentsLazyModule {} diff --git a/src/core/features/course/course-lazy.module.ts b/src/core/features/course/course-lazy.module.ts index e77e5637f..63b2ff507 100644 --- a/src/core/features/course/course-lazy.module.ts +++ b/src/core/features/course/course-lazy.module.ts @@ -83,4 +83,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class CoreCourseLazyModule {} +export default class CoreCourseLazyModule {} diff --git a/src/core/features/course/course-summary-lazy.module.ts b/src/core/features/course/course-summary-lazy.module.ts index ab2c5d617..fc8921506 100644 --- a/src/core/features/course/course-summary-lazy.module.ts +++ b/src/core/features/course/course-summary-lazy.module.ts @@ -35,4 +35,4 @@ const routes: Routes = [ CoreCourseSummaryPageModule, ], }) -export class CoreCourseSummaryLazyModule {} +export default class CoreCourseSummaryLazyModule {} diff --git a/src/core/features/course/course.module.ts b/src/core/features/course/course.module.ts index 1cd36f03a..975db35a6 100644 --- a/src/core/features/course/course.module.ts +++ b/src/core/features/course/course.module.ts @@ -112,14 +112,14 @@ export async function getCourseStandaloneComponents(): Promise[]> const routes: Routes = [ { matcher: buildRegExpUrlMatcher(new RegExp(`^${COURSE_PAGE_NAME}(/deep)*`)), - loadChildren: () => import('@features/course/course-lazy.module').then(m => m.CoreCourseLazyModule), + loadChildren: () => import('@features/course/course-lazy.module'), }, ]; const courseIndexRoutes: Routes = [ { path: CONTENTS_PAGE_NAME, - loadChildren: () => import('@features/course/course-contents-lazy.module').then(m => m.CoreCourseContentsLazyModule), + loadChildren: () => import('@features/course/course-contents-lazy.module'), }, ]; diff --git a/src/core/features/course/services/course-helper.ts b/src/core/features/course/services/course-helper.ts index ff525b53a..6aae35fb0 100644 --- a/src/core/features/course/services/course-helper.ts +++ b/src/core/features/course/services/course-helper.ts @@ -1963,8 +1963,8 @@ export class CoreCourseHelperProvider { * * @returns Course summary page module. */ - async getCourseSummaryRouteModule(): Promise { - return import('../course-summary-lazy.module').then(m => m.CoreCourseSummaryLazyModule); + getCourseSummaryRouteModule(): LazyRoutesModule { + return import('../course-summary-lazy.module'); } /** diff --git a/src/core/features/courses/courses-dashboard-lazy.module.ts b/src/core/features/courses/courses-dashboard-lazy.module.ts index dfd408585..d9dccedab 100644 --- a/src/core/features/courses/courses-dashboard-lazy.module.ts +++ b/src/core/features/courses/courses-dashboard-lazy.module.ts @@ -36,4 +36,4 @@ const routes: Routes = [ CoreCoursesDashboardPage, ], }) -export class CoreCoursesDashboardLazyModule {} +export default class CoreCoursesDashboardLazyModule {} diff --git a/src/core/features/courses/courses-lazy.module.ts b/src/core/features/courses/courses-lazy.module.ts index d51c13f01..a179c7526 100644 --- a/src/core/features/courses/courses-lazy.module.ts +++ b/src/core/features/courses/courses-lazy.module.ts @@ -79,4 +79,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class CoreCoursesLazyModule {} +export default class CoreCoursesLazyModule {} diff --git a/src/core/features/courses/courses-my-lazy.module.ts b/src/core/features/courses/courses-my-lazy.module.ts index 9f41349db..375c7ae8e 100644 --- a/src/core/features/courses/courses-my-lazy.module.ts +++ b/src/core/features/courses/courses-my-lazy.module.ts @@ -39,4 +39,4 @@ const routes: Routes = [ CoreCoursesMyPage, ], }) -export class CoreCoursesMyLazyModule {} +export default class CoreCoursesMyLazyModule {} diff --git a/src/core/features/courses/courses.module.ts b/src/core/features/courses/courses.module.ts index 7cc29f32d..4fbd91139 100644 --- a/src/core/features/courses/courses.module.ts +++ b/src/core/features/courses/courses.module.ts @@ -60,14 +60,14 @@ export async function getCoursesServices(): Promise[]> { const mainMenuHomeChildrenRoutes: Routes = [ { path: CoreDashboardHomeHandlerService.PAGE_NAME, - loadChildren: () => import('./courses-dashboard-lazy.module').then(m => m.CoreCoursesDashboardLazyModule), + loadChildren: () => import('./courses-dashboard-lazy.module'), }, ]; const routes: Routes = [ { path: CoreCoursesMyCoursesMainMenuHandlerService.PAGE_NAME, - loadChildren: () => import('./courses-lazy.module').then(m => m.CoreCoursesLazyModule), + loadChildren: () => import('./courses-lazy.module'), }, ]; diff --git a/src/core/features/courses/services/courses-helper.ts b/src/core/features/courses/services/courses-helper.ts index b066d129a..386ce9590 100644 --- a/src/core/features/courses/services/courses-helper.ts +++ b/src/core/features/courses/services/courses-helper.ts @@ -435,8 +435,8 @@ export class CoreCoursesHelperProvider { * * @returns My courses page module. */ - async getMyRouteModule(): Promise { - return import('../courses-my-lazy.module').then(m => m.CoreCoursesMyLazyModule); + getMyRouteModule(): LazyRoutesModule { + return import('../courses-my-lazy.module'); } /** diff --git a/src/core/features/dataprivacy/dataprivacy-lazy.module.ts b/src/core/features/dataprivacy/dataprivacy-lazy.module.ts index b0431a131..18e5bc91f 100644 --- a/src/core/features/dataprivacy/dataprivacy-lazy.module.ts +++ b/src/core/features/dataprivacy/dataprivacy-lazy.module.ts @@ -35,4 +35,4 @@ const routes: Routes = [ CoreDataPrivacyMainPage, ], }) -export class CoreDataPrivacyLazyModule {} +export default class CoreDataPrivacyLazyModule {} diff --git a/src/core/features/dataprivacy/dataprivacy.module.ts b/src/core/features/dataprivacy/dataprivacy.module.ts index fdf75e04e..75e9e7de5 100644 --- a/src/core/features/dataprivacy/dataprivacy.module.ts +++ b/src/core/features/dataprivacy/dataprivacy.module.ts @@ -25,7 +25,7 @@ import { CoreDataPrivacyCreateDataRequestLinkHandler } from './services/handlers const routes: Routes = [ { path: CORE_DATAPRIVACY_PAGE_NAME, - loadChildren: () => import('./dataprivacy-lazy.module').then(m => m.CoreDataPrivacyLazyModule), + loadChildren: () => import('./dataprivacy-lazy.module'), }, ]; diff --git a/src/core/features/grades/grades-course-lazy.module.ts b/src/core/features/grades/grades-course-lazy.module.ts index 877a0fec9..c3ccc8947 100644 --- a/src/core/features/grades/grades-course-lazy.module.ts +++ b/src/core/features/grades/grades-course-lazy.module.ts @@ -31,4 +31,4 @@ const routes: Routes = [ CoreGradesCoursePageModule, ], }) -export class CoreGradesCourseLazyModule {} +export default class CoreGradesCourseLazyModule {} diff --git a/src/core/features/grades/grades-course-participants-lazy.module.ts b/src/core/features/grades/grades-course-participants-lazy.module.ts index 68400a443..a9e1abce5 100644 --- a/src/core/features/grades/grades-course-participants-lazy.module.ts +++ b/src/core/features/grades/grades-course-participants-lazy.module.ts @@ -27,7 +27,7 @@ const routes: Routes = [ children: conditionalRoutes([ { path: ':userId', - loadChildren: () => import('./grades-course-lazy.module').then(m => m.CoreGradesCourseLazyModule), + loadChildren: () => import('./grades-course-lazy.module'), data: { swipeManagerSource: 'participants' }, }, ], () => CoreScreen.isTablet), @@ -40,4 +40,4 @@ const routes: Routes = [ CoreUserParticipantsPageModule, ], }) -export class CoreGradesCourseParticipantsLazyModule {} +export default class CoreGradesCourseParticipantsLazyModule {} diff --git a/src/core/features/grades/grades-courses-lazy.module.ts b/src/core/features/grades/grades-courses-lazy.module.ts index 785cd4897..821e5546f 100644 --- a/src/core/features/grades/grades-courses-lazy.module.ts +++ b/src/core/features/grades/grades-courses-lazy.module.ts @@ -62,4 +62,4 @@ const routes: Routes = [ CoreGradesCoursesPage, ], }) -export class CoreGradesCoursesLazyModule {} +export default class CoreGradesCoursesLazyModule {} diff --git a/src/core/features/grades/grades.module.ts b/src/core/features/grades/grades.module.ts index dea9a2f1b..533bd16c3 100644 --- a/src/core/features/grades/grades.module.ts +++ b/src/core/features/grades/grades.module.ts @@ -49,17 +49,17 @@ export async function getGradesServices(): Promise[]> { const mainMenuChildrenRoutes: Routes = [ { path: GRADES_PAGE_NAME, - loadChildren: () => import('./grades-courses-lazy.module').then(m => m.CoreGradesCoursesLazyModule), + loadChildren: () => import('./grades-courses-lazy.module'), data: { swipeManagerSource: 'courses' }, }, { path: `${COURSE_PAGE_NAME}/:courseId/${PARTICIPANTS_PAGE_NAME}/:userId/${GRADES_PAGE_NAME}`, - loadChildren: () => import('./grades-course-lazy.module').then(m => m.CoreGradesCourseLazyModule), + loadChildren: () => import('./grades-course-lazy.module'), }, ...conditionalRoutes([ { path: `${COURSE_PAGE_NAME}/${COURSE_INDEX_PATH}/${GRADES_PARTICIPANTS_PAGE_NAME}/:userId`, - loadChildren: () => import('./grades-course-lazy.module').then(m => m.CoreGradesCourseLazyModule), + loadChildren: () => import('./grades-course-lazy.module'), data: { swipeManagerSource: 'participants' }, }, ], () => CoreScreen.isMobile), @@ -68,11 +68,11 @@ const mainMenuChildrenRoutes: Routes = [ const courseIndexRoutes: Routes = [ { path: GRADES_PAGE_NAME, - loadChildren: () => import('./grades-course-lazy.module').then(m => m.CoreGradesCourseLazyModule), + loadChildren: () => import('./grades-course-lazy.module'), }, { path: GRADES_PARTICIPANTS_PAGE_NAME, - loadChildren: () => import('./grades-course-participants-lazy.module').then(m => m.CoreGradesCourseParticipantsLazyModule), + loadChildren: () => import('./grades-course-participants-lazy.module'), }, ]; diff --git a/src/core/features/login/login-credentials-lazy.module.ts b/src/core/features/login/login-credentials-lazy.module.ts index 498025e90..0827e8b98 100644 --- a/src/core/features/login/login-credentials-lazy.module.ts +++ b/src/core/features/login/login-credentials-lazy.module.ts @@ -36,4 +36,4 @@ const routes: Routes = [ CoreLoginCredentialsPage, ], }) -export class CoreLoginCredentialsLazyModule {} +export default class CoreLoginCredentialsLazyModule {} diff --git a/src/core/features/login/login-lazy.module.ts b/src/core/features/login/login-lazy.module.ts index 13e05d136..ff6f82bcf 100644 --- a/src/core/features/login/login-lazy.module.ts +++ b/src/core/features/login/login-lazy.module.ts @@ -78,4 +78,4 @@ const routes: Routes = [ CoreLoginEmailSignupPage, ], }) -export class CoreLoginLazyModule {} +export default class CoreLoginLazyModule {} diff --git a/src/core/features/login/login-reconnect-lazy.module.ts b/src/core/features/login/login-reconnect-lazy.module.ts index 156ebd210..22084638f 100644 --- a/src/core/features/login/login-reconnect-lazy.module.ts +++ b/src/core/features/login/login-reconnect-lazy.module.ts @@ -36,4 +36,4 @@ const routes: Routes = [ CoreLoginReconnectPage, ], }) -export class CoreLoginReconnectLazyModule {} +export default class CoreLoginReconnectLazyModule {} diff --git a/src/core/features/login/login.module.ts b/src/core/features/login/login.module.ts index 7d15b2175..b0d3d8fbd 100644 --- a/src/core/features/login/login.module.ts +++ b/src/core/features/login/login.module.ts @@ -38,7 +38,7 @@ export async function getLoginServices(): Promise[]> { const appRoutes: Routes = [ { path: 'login', - loadChildren: () => import('./login-lazy.module').then(m => m.CoreLoginLazyModule), + loadChildren: () => import('./login-lazy.module'), canActivate: [redirectGuard], }, ]; diff --git a/src/core/features/login/services/login-helper.ts b/src/core/features/login/services/login-helper.ts index fcb3abbd2..849c357f3 100644 --- a/src/core/features/login/services/login-helper.ts +++ b/src/core/features/login/services/login-helper.ts @@ -1451,8 +1451,8 @@ export class CoreLoginHelperProvider { * * @returns Reconnect page route module. */ - async getReconnectRouteModule(): Promise { - return import('@features/login/login-reconnect-lazy.module').then(m => m.CoreLoginReconnectLazyModule); + getReconnectRouteModule(): LazyRoutesModule { + return import('@features/login/login-reconnect-lazy.module'); } /** @@ -1460,8 +1460,8 @@ export class CoreLoginHelperProvider { * * @returns Credentials page route module. */ - async getCredentialsRouteModule(): Promise { - return import('@features/login/login-credentials-lazy.module').then(m => m.CoreLoginCredentialsLazyModule); + getCredentialsRouteModule(): LazyRoutesModule { + return import('@features/login/login-credentials-lazy.module'); } /** diff --git a/src/core/features/mainmenu/mainmenu-home-lazy.module.ts b/src/core/features/mainmenu/mainmenu-home-lazy.module.ts index 99d14e33d..a05414831 100644 --- a/src/core/features/mainmenu/mainmenu-home-lazy.module.ts +++ b/src/core/features/mainmenu/mainmenu-home-lazy.module.ts @@ -57,4 +57,4 @@ function buildRoutes(injector: Injector): Routes { CoreMainMenuHomePage, ], }) -export class CoreMainMenuHomeLazyModule {} +export default class CoreMainMenuHomeLazyModule {} diff --git a/src/core/features/mainmenu/mainmenu-lazy.module.ts b/src/core/features/mainmenu/mainmenu-lazy.module.ts index 0d71ebe0a..98c8fd587 100644 --- a/src/core/features/mainmenu/mainmenu-lazy.module.ts +++ b/src/core/features/mainmenu/mainmenu-lazy.module.ts @@ -38,11 +38,11 @@ function buildRoutes(injector: Injector): Routes { children: [ { path: CoreMainMenuHomeHandlerService.PAGE_NAME, - loadChildren: () => import('./mainmenu-home-lazy.module').then(m => m.CoreMainMenuHomeLazyModule), + loadChildren: () => import('./mainmenu-home-lazy.module'), }, { path: CoreMainMenuProvider.MORE_PAGE_NAME, - loadChildren: () => import('./mainmenu-more-lazy.module').then(m => m.CoreMainMenuMoreLazyModule), + loadChildren: () => import('./mainmenu-more-lazy.module'), }, ...mainMenuRoutes.children, ], @@ -63,4 +63,4 @@ function buildRoutes(injector: Injector): Routes { { provide: ROUTES, multi: true, useFactory: buildRoutes, deps: [Injector] }, ], }) -export class CoreMainMenuLazyModule {} +export default class CoreMainMenuLazyModule {} diff --git a/src/core/features/mainmenu/mainmenu-more-lazy.module.ts b/src/core/features/mainmenu/mainmenu-more-lazy.module.ts index 0c3f9f667..4f3b1aa11 100644 --- a/src/core/features/mainmenu/mainmenu-more-lazy.module.ts +++ b/src/core/features/mainmenu/mainmenu-more-lazy.module.ts @@ -53,4 +53,4 @@ function buildRoutes(injector: Injector): Routes { CoreMainMenuMorePage, ], }) -export class CoreMainMenuMoreLazyModule {} +export default class CoreMainMenuMoreLazyModule {} diff --git a/src/core/features/mainmenu/mainmenu-reload-lazy.module.ts b/src/core/features/mainmenu/mainmenu-reload-lazy.module.ts index b1aaa8baa..79a20778a 100644 --- a/src/core/features/mainmenu/mainmenu-reload-lazy.module.ts +++ b/src/core/features/mainmenu/mainmenu-reload-lazy.module.ts @@ -33,4 +33,4 @@ const routes: Routes = [ CoreMainMenuReloadPage, ], }) -export class CoreMainMenuReloadLazyModule {} +export default class CoreMainMenuReloadLazyModule {} diff --git a/src/core/features/mainmenu/mainmenu.module.ts b/src/core/features/mainmenu/mainmenu.module.ts index 4f423f833..23d5ab607 100644 --- a/src/core/features/mainmenu/mainmenu.module.ts +++ b/src/core/features/mainmenu/mainmenu.module.ts @@ -46,12 +46,12 @@ const appRoutes: Routes = [ }, { path: 'main', - loadChildren: () => import('./mainmenu-lazy.module').then(m => m.CoreMainMenuLazyModule), + loadChildren: () => import('./mainmenu-lazy.module'), canActivate: [authGuard], }, { path: 'reload', - loadChildren: () => import('./mainmenu-reload-lazy.module').then( m => m.CoreMainMenuReloadLazyModule), + loadChildren: () => import('./mainmenu-reload-lazy.module'), }, ]; diff --git a/src/core/features/policy/policy-lazy.module.ts b/src/core/features/policy/policy-lazy.module.ts index 7fc310608..f2ab53d14 100644 --- a/src/core/features/policy/policy-lazy.module.ts +++ b/src/core/features/policy/policy-lazy.module.ts @@ -41,4 +41,4 @@ const routes: Routes = [ CorePolicyAcceptancesPage, ], }) -export class CorePolicyLazyModule {} +export default class CorePolicyLazyModule {} diff --git a/src/core/features/policy/policy.module.ts b/src/core/features/policy/policy.module.ts index 407713570..9750842f3 100644 --- a/src/core/features/policy/policy.module.ts +++ b/src/core/features/policy/policy.module.ts @@ -27,7 +27,7 @@ import { CoreContentLinksDelegate } from '@features/contentlinks/services/conten const routes: Routes = [ { path: POLICY_PAGE_NAME, - loadChildren: () => import('./policy-lazy.module').then(m => m.CorePolicyLazyModule), + loadChildren: () => import('./policy-lazy.module'), }, ]; diff --git a/src/core/features/reportbuilder/reportbuilder-lazy.module.ts b/src/core/features/reportbuilder/reportbuilder-lazy.module.ts index c5064d388..7e142f6dd 100644 --- a/src/core/features/reportbuilder/reportbuilder-lazy.module.ts +++ b/src/core/features/reportbuilder/reportbuilder-lazy.module.ts @@ -41,4 +41,4 @@ const routes: Routes = [ CoreReportBuilderReportPage, ], }) -export class CoreReportBuilderLazyModule {} +export default class CoreReportBuilderLazyModule {} diff --git a/src/core/features/reportbuilder/reportbuilder.module.ts b/src/core/features/reportbuilder/reportbuilder.module.ts index 98680d344..ba5cdca4b 100644 --- a/src/core/features/reportbuilder/reportbuilder.module.ts +++ b/src/core/features/reportbuilder/reportbuilder.module.ts @@ -23,7 +23,7 @@ import { CoreReportBuilderHandler, CoreReportBuilderHandlerService } from './ser const routes: Routes = [ { path: CoreReportBuilderHandlerService.PAGE_NAME, - loadChildren: () => import('./reportbuilder-lazy.module').then(m => m.CoreReportBuilderLazyModule), + loadChildren: () => import('./reportbuilder-lazy.module'), }, ]; diff --git a/src/core/features/search/search-lazy.module.ts b/src/core/features/search/search-lazy.module.ts index 55d6d5862..05bc71bbe 100644 --- a/src/core/features/search/search-lazy.module.ts +++ b/src/core/features/search/search-lazy.module.ts @@ -50,4 +50,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class CoreSearchLazyModule {} +export default class CoreSearchLazyModule {} diff --git a/src/core/features/search/search.module.ts b/src/core/features/search/search.module.ts index c7fc4375c..8a3ea5be0 100644 --- a/src/core/features/search/search.module.ts +++ b/src/core/features/search/search.module.ts @@ -44,7 +44,7 @@ export async function getSearchServices(): Promise[]> { const mainMenuChildrenRoutes: Routes = [ { path: CORE_SEARCH_PAGE_NAME, - loadChildren: () => import('./search-lazy.module').then(m => m.CoreSearchLazyModule), + loadChildren: () => import('./search-lazy.module'), }, ]; diff --git a/src/core/features/settings/settings-lazy.module.ts b/src/core/features/settings/settings-lazy.module.ts index 69007a407..84be212d3 100644 --- a/src/core/features/settings/settings-lazy.module.ts +++ b/src/core/features/settings/settings-lazy.module.ts @@ -45,7 +45,7 @@ const sectionRoutes: Routes = [ }, { path: SHAREDFILES_PAGE_NAME, - loadChildren: () => import('@features/sharedfiles/sharedfiles-lazy.module').then(m => m.CoreSharedFilesLazyModule), + loadChildren: () => import('@features/sharedfiles/sharedfiles-lazy.module'), }, { path: 'about', @@ -114,4 +114,4 @@ const routes: Routes = [ CoreSettingsErrorLogPage, ], }) -export class CoreSettingsLazyModule {} +export default class CoreSettingsLazyModule {} diff --git a/src/core/features/settings/settings-site-lazy.module.ts b/src/core/features/settings/settings-site-lazy.module.ts index 82ccd0259..67d0c4ad1 100644 --- a/src/core/features/settings/settings-site-lazy.module.ts +++ b/src/core/features/settings/settings-site-lazy.module.ts @@ -61,4 +61,4 @@ function buildRoutes(injector: Injector): Routes { CoreSharedModule, ], }) -export class CoreettingsSiteLazyModule {} +export default class CoreettingsSiteLazyModule {} diff --git a/src/core/features/settings/settings.module.ts b/src/core/features/settings/settings.module.ts index dd77dbf1b..72a98a2d8 100644 --- a/src/core/features/settings/settings.module.ts +++ b/src/core/features/settings/settings.module.ts @@ -37,18 +37,18 @@ export async function getSettingsServices(): Promise[]> { const appRoutes: Routes = [ { path: 'settings', - loadChildren: () => import('./settings-lazy.module').then(m => m.CoreSettingsLazyModule), + loadChildren: () => import('./settings-lazy.module'), }, ]; const mainMenuMoreRoutes: Routes = [ { path: 'settings', - loadChildren: () => import('./settings-lazy.module').then(m => m.CoreSettingsLazyModule), + loadChildren: () => import('./settings-lazy.module'), }, { path: 'preferences', - loadChildren: () => import('./settings-site-lazy.module').then(m => m.CoreettingsSiteLazyModule), + loadChildren: () => import('./settings-site-lazy.module'), }, ]; diff --git a/src/core/features/sharedfiles/sharedfiles-lazy.module.ts b/src/core/features/sharedfiles/sharedfiles-lazy.module.ts index 878a53cf9..55c890622 100644 --- a/src/core/features/sharedfiles/sharedfiles-lazy.module.ts +++ b/src/core/features/sharedfiles/sharedfiles-lazy.module.ts @@ -42,4 +42,4 @@ const routes: Routes = [ CoreSharedFilesChooseSitePage, ], }) -export class CoreSharedFilesLazyModule {} +export default class CoreSharedFilesLazyModule {} diff --git a/src/core/features/sharedfiles/sharedfiles.module.ts b/src/core/features/sharedfiles/sharedfiles.module.ts index 45d715d00..26d6562a9 100644 --- a/src/core/features/sharedfiles/sharedfiles.module.ts +++ b/src/core/features/sharedfiles/sharedfiles.module.ts @@ -45,7 +45,7 @@ export async function getSharedFilesServices(): Promise[]> { const routes: Routes = [ { path: SHAREDFILES_PAGE_NAME, - loadChildren: () => import('./sharedfiles-lazy.module').then(m => m.CoreSharedFilesLazyModule), + loadChildren: () => import('./sharedfiles-lazy.module'), }, ]; diff --git a/src/core/features/sitehome/sitehome-lazy.module.ts b/src/core/features/sitehome/sitehome-lazy.module.ts index ce14d218e..7a0d4a38d 100644 --- a/src/core/features/sitehome/sitehome-lazy.module.ts +++ b/src/core/features/sitehome/sitehome-lazy.module.ts @@ -38,4 +38,4 @@ const routes: Routes = [ CoreSiteHomeIndexPage, ], }) -export class CoreSiteHomeLazyModule {} +export default class CoreSiteHomeLazyModule {} diff --git a/src/core/features/sitehome/sitehome.module.ts b/src/core/features/sitehome/sitehome.module.ts index c968d4625..fc597d533 100644 --- a/src/core/features/sitehome/sitehome.module.ts +++ b/src/core/features/sitehome/sitehome.module.ts @@ -37,7 +37,7 @@ export async function getSiteHomeServices(): Promise[]> { const mainMenuHomeRoutes: Routes = [ { path: CoreSiteHomeHomeHandlerService.PAGE_NAME, - loadChildren: () => import('./sitehome-lazy.module').then(m => m.CoreSiteHomeLazyModule), + loadChildren: () => import('./sitehome-lazy.module'), }, ]; diff --git a/src/core/features/tag/tag-lazy.module.ts b/src/core/features/tag/tag-lazy.module.ts index 12b563ee2..746224299 100644 --- a/src/core/features/tag/tag-lazy.module.ts +++ b/src/core/features/tag/tag-lazy.module.ts @@ -95,4 +95,4 @@ function buildRoutes(injector: Injector): Routes { }, ], }) -export class CoreTagLazyModule {} +export default class CoreTagLazyModule {} diff --git a/src/core/features/tag/tag.module.ts b/src/core/features/tag/tag.module.ts index b64146380..9a19ace85 100644 --- a/src/core/features/tag/tag.module.ts +++ b/src/core/features/tag/tag.module.ts @@ -43,7 +43,7 @@ export async function getTagServices(): Promise[]> { const routes: Routes = [ { path: CoreTagMainMenuHandlerService.PAGE_NAME, - loadChildren: () => import('./tag-lazy.module').then(m => m.CoreTagLazyModule), + loadChildren: () => import('./tag-lazy.module'), }, ]; diff --git a/src/core/features/user/user-app-lazy.module.ts b/src/core/features/user/user-app-lazy.module.ts index e5126a789..5424acbea 100644 --- a/src/core/features/user/user-app-lazy.module.ts +++ b/src/core/features/user/user-app-lazy.module.ts @@ -33,4 +33,4 @@ const routes: Routes = [ CoreUserCompleteProfilePage, ], }) -export class CoreUserAppLazyModule {} +export default class CoreUserAppLazyModule {} diff --git a/src/core/features/user/user-course-lazy.module.ts b/src/core/features/user/user-course-lazy.module.ts index a0a9cb34c..eebc44954 100644 --- a/src/core/features/user/user-course-lazy.module.ts +++ b/src/core/features/user/user-course-lazy.module.ts @@ -27,7 +27,7 @@ const routes: Routes = [ children: conditionalRoutes([ { path: ':userId', - loadChildren: () => import('@features/user/user-profile-lazy.module').then(m => m.CoreUserProfileLazyModule), + loadChildren: () => import('@features/user/user-profile-lazy.module'), data: { swipeManagerSource: 'participants' }, }, ], () => CoreScreen.isTablet), @@ -40,4 +40,4 @@ const routes: Routes = [ CoreUserParticipantsPageModule, ], }) -export class CoreUserCourseLazyModule {} +export default class CoreUserCourseLazyModule {} diff --git a/src/core/features/user/user-lazy.module.ts b/src/core/features/user/user-lazy.module.ts index f76ce4e06..76284afc7 100644 --- a/src/core/features/user/user-lazy.module.ts +++ b/src/core/features/user/user-lazy.module.ts @@ -26,7 +26,7 @@ const routes: Routes = [ }, { path: 'profile', - loadChildren: () => import('./user-profile-lazy.module').then( m => m.CoreUserProfileLazyModule), + loadChildren: () => import('./user-profile-lazy.module'), }, { path: 'about', @@ -44,4 +44,4 @@ const routes: Routes = [ CoreUserAboutPage, ], }) -export class CoreUserLazyModule {} +export default class CoreUserLazyModule {} diff --git a/src/core/features/user/user-profile-lazy.module.ts b/src/core/features/user/user-profile-lazy.module.ts index 5a184f5e8..c3257aaca 100644 --- a/src/core/features/user/user-profile-lazy.module.ts +++ b/src/core/features/user/user-profile-lazy.module.ts @@ -34,4 +34,4 @@ const routes: Routes = [ CoreUserProfilePage, ], }) -export class CoreUserProfileLazyModule {} +export default class CoreUserProfileLazyModule {} diff --git a/src/core/features/user/user.module.ts b/src/core/features/user/user.module.ts index b40bce2bb..373a922f3 100644 --- a/src/core/features/user/user.module.ts +++ b/src/core/features/user/user.module.ts @@ -63,19 +63,19 @@ export async function getUsersServices(): Promise[]> { const appRoutes: Routes = [ { path: 'user', - loadChildren: () => import('@features/user/user-app-lazy.module').then(m => m.CoreUserAppLazyModule), + loadChildren: () => import('@features/user/user-app-lazy.module'), }, ]; const routes: Routes = [ { path: 'user', - loadChildren: () => import('@features/user/user-lazy.module').then(m => m.CoreUserLazyModule), + loadChildren: () => import('@features/user/user-lazy.module'), }, ...conditionalRoutes([ { path: `${COURSE_PAGE_NAME}/${COURSE_INDEX_PATH}/${PARTICIPANTS_PAGE_NAME}/:userId`, - loadChildren: () => import('@features/user/user-profile-lazy.module').then(m => m.CoreUserProfileLazyModule), + loadChildren: () => import('@features/user/user-profile-lazy.module'), data: { swipeManagerSource: 'participants', }, @@ -86,7 +86,7 @@ const routes: Routes = [ const courseIndexRoutes: Routes = [ { path: PARTICIPANTS_PAGE_NAME, - loadChildren: () => import('@features/user/user-course-lazy.module').then(m => m.CoreUserCourseLazyModule), + loadChildren: () => import('@features/user/user-course-lazy.module'), }, ];