With or without the --no-module flag I get the same result. In app-routing.module.ts the cli command adds the following line:
loadChildren: () => import('./page/page.module').then(m => m.PagePageModule)
while previously it would add:
path: 'page', loadChildren: './page/page/page.module#PagePageModule'
The way page.module.ts is generated has changed as well: the following lines are missing:
const routes: Routes = [
and inside the imports array
is missing while it has added (and generated)
I find it quite confusing because I thought that in the old approach pages were lazy loaded as well. This leaves me with the following questions:
- Are pages indeed lazy loaded int the old approach.
- If so, why this change.
- Should I restructure my existing pages to use the new approach.