`import { Routes } from ‘@angular/router’;
export const routes: Routes = [
{
path: '', // Empty path for root-level admin section
children: [
{
path: 'adminHome',
// component: AdminHomeComponent // Specify the component to
loadComponent: () =>
import('./modules/admin/admin-home/admin-home.component').then(
(m) => m.AdminHomeComponent
),
children: [
{
path: 'createCustomer',
loadComponent: () =>
import(
'./modules/admin/create-customer/create-customer.component'
).then((m) => m.CreateCustomerComponent),
},
{
path:'createcustomerarea',
loadChildren:()=>
import(
'./modules/admin/customer-service-area/customer-service-area.component'
).then((m) =>m.CustomerServiceAreaComponent)
}
],
},
],
},
];`
I am trying to lazy loading with standalone component in angular 17
New contributor
Developer Aj Aju is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1