By Scott Miller, Senior Software Engineer, Pulsion Technology
The first version of Angular was extremely popular: it was widely adopted by the tech community, which was aided by it having the backing of Google. In Pulsion, we’ve developed a number of web applications using Angular 1 in recent years. Overall, it was found to be very responsive to use, and pretty easy to pick up. The MVVM pattern it used was familiar to anyone who had worked with any kind of MVC framework in the past. However, it did have its drawbacks. It was found that directives in particular were really not intuitive. Also, if you had a number of different nested layers of scope, things could start to get confusing really quickly! So it was with this background that we looked into the modern version of Angular (version 4 at present, version 5 currently in beta).
The first thing of note is how different Angular 2+ is from Angular 1. It’s essentially a completely different framework, which has simply retained the Angular name. They’ve moved Angular to using TypeScript, using a component architecture where each component will follow MVC/MVVM pattern. The use of TypeScript means it’s easier to write better code, and the component architecture means it is easy to re-use code. It also has a marked performance improvement compared to Angular 1.
There did seem to be some down-sides to Angular 2+, however. Although it’s easy enough to write a basic demo app, there looks to be a fairly big learning curve involved if you’re going to be getting into the complexities presented by an enterprise level web application development project. In addition, the 2-way data binding that is used by Angular can be as much of a curse in some scenarios as it is a blessing in others. It’s great if you’ve got a simple webpage with a few fields. However, if you’ve got a complex webpage consisting of nested components with lots of inter-dependencies in fields, it could become very easy to lose track of exactly what the 2-way data binding is actually doing, behind the scenes: it simply becomes “magic”. And to a developer, “magic” isn’t good!
Meantime, please feel free to leave a comment, or if you have any questions on this or any other software development topic, then please don’t hesitate to contact us on firstname.lastname@example.org or 0141 352 2280.