What’s new in Angular 5: easier progressive web apps
- 03 August, 2017 20:00
Despite the “5” designation, the upgrade will actually be just the fourth release for the framework, which already has undergone a rewrite since the 1.0 version, initially called AngularJS, debuted in 2012. Angular 5 is now in beta release and is scheduled for production release on September 18.
Its features include:
- An emphasis on making it easier to build progressive web apps, so apps can be cached in the browser.
- A build optimizer that makes the application smaller by eliminating unnecessary code.
- Making Material Design components compatible with server-side rendering.
The progressive web apps concept, the product of a joint effort between Google and Mozilla, is about enabling development of browser-based apps that offer a superior, native-like experience.
Supporting progressive web apps in Angular today requires a lot of expertise on the developers’ part; version 5 is intended to make usage easier. “We’re shooting to try and make progressive web apps something that everyone would use,” said Brad Green, a Google engineering director. “We’re trying to find the right set of defaults so that it just would be the default option for most developers, for both desktop and mobile web.”
Angular 6 on the horizon
Following Angular 5, Google will offer Angular 6 in March or April 2018, if the current release pace golds. Google has not yet decided what features might show up in that release but says it will repeat themes of Angular 5: “Easier, smaller, faster is the theme for version 5. We’ll continue that theme for version 6, just making [developers’] lives easier, making it possible to deliver apps better for their users,” Green said.
Angular’s busy release schedule
Angular 5 follows closely the releases of versions 2 and 4, which arrived in September 2016 and March 2017, respectively, skipping over a version 3 designation. (Because the router for Angular already had reached version 4 by the time Angular 3 was due, Google just went right to calling the upgrade itself Angular 4.)
Angular 2 also offered a much cleaner component model. Interoperation with technologies such as web components was also a focus in Angular 2.
Angular 4, meanwhile, offered view-engine improvements and code-generation reductions. The latest version of Angular was the 4.3 upgrade, released in July and featuring HttpClient, which provided a smaller, easier-to-use library for making HTTP requests.
Angular 4.3 also has an attribute,
@.disabled, for conditionally disabling animations as well as new router life cycle events. Since the 4.0 version, Angular also enhanced animations so parent and child elements can be coordinated across page transitions.
Dependency injection, HTML template remain core advantages
AngularJS’s selling points at the outset included dependency injection, particularly useful for assembling data services for applications, along with use of an HTML template to compose components. Over all the subsequent vesions, these have remained key features. Developers still compose components with an HTML component that connects to TypeScript code for imperative parts of the program.
Google says Angular has succeeded because it offers a “batteries included” approach to development, with developers not burdened with figuring out which internationalization library or animation to to use, or how to do HTTP or forms.