My Angular project folder structure is
+-- app.module.ts
+-- app-routing.ts
+-- app.component.ts
+-- product/
| +-- product.module.ts
| +-- product-routing.ts
| +-- product-detail/
| | +--product-detail.component.ts
| | +--product-detail.component.html
In my app-routing.ts
{path:'products',loadChildren:'app/products/products.module#ProductsModule'}
In my product-routing.ts
{ path: 'detail', component: ProductDetailComponent }
When I load the url - page/products/detail , I get the following error
> ERROR Error: Uncaught (in promise): Error: Cannot find module "app/products/products.module".
Error: Cannot find module "app/products/products.module".
Steps tried
tried changing 'app/products/products.module#ProductsModule'
to './products/products.module#ProductsModule'. not solved.
Where I have went wrong? Any help is appreciated.