This topic covers module optimization, moving items out of the main module which is app.modules.ts, lazy loading and sharing modules etc.
When adding a new component, directive etc, and we have multiple modules then we need to specify the module as well when creating these via the CLI.
> ng g c Hello --spec false --app
> Angular Samples
> MyRecipes Full Project Setup
> Angular 6 Samples
When adding a new component, directive etc, and we have multiple modules then we need to specify the module as well when creating these via the CLI.
> ng g c Hello --spec false --app
- Moving Routes out of the main module
- Moving Recipes related components declaration and routes to own feature module
- Sharing modules
- Moving Shopping List components to own feature module
- Moving Auth components and routes to own feature module
- Lazy Loading Recipes Module
- Protecting Lazy Loaded Routes with canLoad
> Angular Samples
> MyRecipes Full Project Setup
> Angular 6 Samples