Angular 8 is finally here!
This version is a major release for the entire Angular framework, Angular Material and the CLI.
- Ivy renderer to be available as an opt-in preview
- Faster startup time on modern browsers
- New APIs to interact with the CLI
Fortunately, Angular maintains a high degree of stability across major versions. The public API supports features for the next two releases. This means that a feature that is deprecated with Angular 8 will continue to work in the following two major releases (9 and 10).
There is a huge amount of excitement in the Angular community for the upcoming Ivy renderer. The Angular team has announced that they will be including in Ivy in Angular 8 as an opt-in preview.
As you may already know, Angular apps are a little on the heavy side when it comes to file size and memory usage. Ivy aims to change this and improve the user experience of Angular apps. It is definitely something you should care about!
- Producing smaller application chunks, so it will take browsers less time to download and interpret Angular apps
- Better template type checking at development time to reduce runtime errors
- Greatly reducing rebuild times
- Compiled code is much easier for humans to read and understand
- Broad compatibility with existing Angular apps, so no code change should be necessary.
If this sounds interesting, go ahead and opt into Ivy and let me know your thoughts!
This allows modern browsers to download the smaller, more efficient bundles that load and render faster than before.
Support for Web Workers
A nifty new feature in Angular 8 will that the CLI will support the bundling of web workers.
Web workers are great innovation in front-end development, which make it possible to run CPU intensive tasks in separate a thread. Service workers can even continue to run after the user closes the browser window.
The code that you run in a web worker can’t be in the same file as the application files. It must be in a separate file as it executes in a different thread, outside the Angular zone. The Angular CLI did not work well with bundling of service workers in previous versions.
Some features are now deprecated as of Angular 8, including:
loadChildrenstring syntax for lazy loaded routes
ngModelwith reactive forms