Angular 2 is the latest iteration of the amazingly successful application development framework that has been developed by Google. Angular 2 provides everything that is needed to develop complex web based and mobile applications. This includes data management, HTTP services and form handling. So what is new in Angular 2? Why has this update got so many developers up in arms? Below we take a look at some of the major changes in Angular 2, and why they might be bad for existing Angular 1.3 developers.
There can be no doubt that the release of Angular 2 has caused quite a stir. The controversy stems from the almost entirely new direction that Google is taking with Angular 2.
Google has stated that the new version of Angular will be mobile focused, entirely modular and modern enough to be used across all mainstream browsers for some time to come.
Developers were pleased with this new direction until it became clear that Google has decided to grandfather applications developed using the version 1.3 of Angular. They will not function under Angular 2. Furthermore, no assisted migration tools will be made available to developers who want to redevelop their apps under Angular 2.
This has left the development community in turmoil, as dedicated Angular 1.3 developers now face the prospect of either manually migrating their codebase to Angular 2, or switching to a different development platform and starting from scratch.
Angular 2 improves on the modularity of app design by improving Dependency Injection (DI). DI is a development method whereby an application can have its dependencies pushed to it from another source, rather than creating them itself. This leads to a much more modular approach to developing complex apps.
AtScript sits at the heart of this new improved DI capability. Possibly the reason why Google decided to make it the default scripting language in Angular 2. AtScript provides all of the tools for dependency injection as part of its instruction set.
Templating has also been improved with version 2 of Angular, with the template compilation process now being asynchronous. This has been done to bring the power of dependency injection into the compile stage. Dependencies can be pulled in as and when needed as part of the compile. This again helps move to a more modular approach to app development.
For existing developers with complex legacy apps that will need to be redeveloped under Angular 2, then this release might seem like something of a slap in the face from Google. However, overall, the new changes have resulted in a much better development platform, more in line with modern development methodologies.