AngularJS 2.0

As dust clears off the ng-conf we can now sit down and reflect about a few interesting things that were presented in the conference. In many talks the core team of Angular made references to the future of the superheroic framework that we would like to share with you.

It seems that internally at Google more and more teams are embracing Angular. To help with the adoption the team launched a version that plays along well with the in-house development language Dart, called AngularDart. That process gave the team a different perspective and ideas, some of which will likely to drive AngularJS 2.0

Once they launched the Dart tailored version of the framework, a growing sense of skepticism invade the community on the future of the Javascript version. Angular is an open-source project and the community can move it forward or fork it whenever they want, however having Google’s blessing always helps. The response from the Angular team was that they will demonstrate release after release that they are committed to AngularJS, they promised more frequent releases.

The efforts of Angular’s technical lead team are now concentrated in the 2.0 version of the framework. This means that the version 1.0 is not likely to see major architectural changes, but rather small improvements.

Igor Minar summarized the difference between AngularJS 1.X and 2.0 by saying…

AngularJS 1.X is built for current browsers while AngularJS 2.0 is being built for the browsers of the future.

What they mean by that is browsers supporting the next version of Javascript -EcmaScript 6 (or harmony)- and also html5. This also means a departure from the support for existent old browsers.

ES6 is a more expressive language than ES5 (current version of JS) that will likely help write cleaner and easier to understand code. Also since some of these features (classes, modules, mixins, …) will be supported by the browsers directly they will be more performant than using polyfills.

Another huge piece of the next web is Web Components. Which are new semantics for html. For instance, they allow you to define templates, which are huge deal in single-page applications.

The team is already developing the new version using ES6 and using a transpiler to transform the code from ES6 to ES5. You’d still be able to use ES5 to write your code using AngularJS 2.0, although you will not have the benefits of the expressiveness of the new syntax.

In future posts we will discuss in detail about specific changes to the AngularJS API. Stay tuned…

comments powered by Disqus