Since Angular 8's official launch in May 2019, there has been a steady stream of updates and refinements. The next major release, Angular 9, is anticipated around November 2019. Notable post-release developments include Ivy becoming the default rendering engine, the CLI officially adding ng deploy support, and numerous other enhancements.

What’s New

Tracking Location Changes from AngularJS

A new onChange hook has been introduced, allowing you to detect browser URL modifications that originate from an AngularJS application. The following snippet from a spec file demonstrates how to pass changeListener and errorHandler functions.

$location.onChange(changeListener, errorHandler);
function changeListener(url: string, state: unknown) 
{ 
      return undefined; 
} 
function errorHandler(e: Error) {}

Testing Utilities

Two new unit test helpers have been added to simplify testing Angular services while migrating an AngularJS project:

TypeScript Version

The 8.2.0 release requires TypeScript 3.5.x or later.

Automatic Migration from Renderer

The older Renderer has been deprecated for a while in favor of Renderer2. Now, running ng update will automatically migrate your existing code to use Renderer2.

Access to $element in Upgraded Components

Previously, an upgraded component using a template function did not have access to the $element or $attrs arguments. Now, the $element parameter is provided to such components.

Deprecations

Platform WebWorker

The @angular/platform-webworker and @angular/platform-webworker-dynamic packages are now officially deprecated. The Angular team concluded that running an Angular application on a Web Worker is not advisable due to inadequate API and tooling support. You can read the full rationale in the relevant commit.

Web Tracing Framework

Integration with the Web Tracing Framework (WTF) for performance analysis is now deprecated. Since the project is unmaintained and fails across most applications, this support has been phased out.

Breaking Changes

Slice Pipe Type Restriction

The SlicePipe previously accepted a value of type any. It now only works with an array, a string, null, or undefined. Using any other data type will trigger a compilation error.

Angular CLI

  • The default application’s root component has been redesigned to display a few commands directly in the UI.
  • The ng deploy command has been introduced, enabling the use of deployment builders crafted by the community.
  • When generating a new module, you can now specify whether it should be lazy-loaded. For instance, the command below creates a ProductModule and automatically adds the routing configuration to app-routing.module for lazy loading.
ng g module product --routing true --route product --module app
  • Angular 8 introduced differential loading, which initially built the application twice—once for ES2015 and once for ES5—causing considerable confusion among developers, as reflected in numerous questions on StackOverflow and GitHub. With the latest CLI releases, this behavior is no longer visible. Starting with CLI 8.3.0, only the ES2015 build is produced, and the resulting bundles are then down-leveled directly to ES5.

Conclusion

Angular 9.next is already available, and Ivy is now the default rendering engine. In the coming months, a release candidate will likely be published, offering more clarity on what to expect from the final Angular 9 release. In the meantime, a range of performance enhancements and bug fixes are underway in parallel.