Hi, I am starting new project with Ionic 5- Angular 11 with the tabs template.
To Lazy load components I was doing this following this article an this article:
import { NgModule } from '@angular/core';
import { PreloadAllModules, RouterModule, Routes } from '@angular/router';
const routes: Routes = [
{
path: '',
loadChildren: './tabs/tabs.module#TabsPageModule'
data: { preload: true },
}
];
@NgModule({
imports: [
RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules })
],
exports: [RouterModule]
})
export class AppRoutingModule {}
But when I launch the app with ionic serve ir not loads the app with this error:
ERROR Error: Uncaught (in promise): Error: Cannot find module ‘./tabs/tabs.module’
Can someone help me with this?
1 post - 1 participant