-
Notifications
You must be signed in to change notification settings - Fork 676
feat: update to Angular 8 #679
Conversation
The main noticeable change in the removal of `@nguniversal/module-map-ngfactory-loader`. This is because now in Angular 8 we support standard import syntax which no longer require custom logic to support lazy loading.
Example
```ts
loadChildren: () => import('./lazy/lazy.module').then(m => m.LazyModule)
```
instead of
```ts
loadChildren: './lazy/lazy.module#LazyModule'
```
01d9b0e to
d4e4241
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should always optimize components css in server builds.
alan-agius4
commented
Jun 4, 2019
//cc @CaerusKaru
alan-agius4
commented
Jun 4, 2019
We should also probably update the schematics not to add this dependency
Hi - We are already making few other changes to the schematic to make this work.
Can you refer to vikerman/v8-lazy@515239b for other changes required to make this work - Essentially moving all dependencies to @angular and @nguniversal out of server.ts in to main.ts.
This is required for dynamic imports to properly work on the server or it would fail due to Angular being bundled as two copies in server.ts bundle and main.ts bundle.
- Will look into removing the ModuleMapLoader from the schematics - But it's not breaking anything for now
- Turning on CSS animations is a good idea
m98
commented
Jun 20, 2019
@vikerman would you please review and add essentials actions to this PR?
It's a while Angular 8 is out, and still, we can't use it with SSR.
The main noticeable change in the removal of
@nguniversal/module-map-ngfactory-loader. This is because now in Angular 8 we support standard import syntax which no longer require custom logic to support lazy loading.Example
instead of
loadChildren: './lazy/lazy.module#LazyModule'