Angular · Middle · Question 63 of 75
How do you lazy-load a group of child routes?
{ path: 'admin', loadChildren: () => import('./admin/admin.routes').then((m) => m.ADMIN_ROUTES) }- ✓Correct answer: Use
loadChildrenthat imports a routes array - 2Use
childrenwith dynamicimportin each component - 3Put the routes in a separate app
Explanation
The whole feature (components, services from route providers) goes into a separate chunk loaded on first visit.