Is the Angular Decline a Myth?

Written by Andrew Zola

February 15, 2018

The evolution of front-end development over the last two decades has been nothing short of remarkable. In the early nineteen-nineties, front-end developers focused mainly on functionality while the layout was an afterthought. This is because there weren’t many tools and techniques to work with and CSS and JavaScript that we know today didn’t even exist.

In a landscape dominated by Internet Explorer, Opera, and Netscape, front-development was concentrated on constructing tables to give the content a broad appeal. Developers were also constantly working to resolve browser bugs, but performance issues and browser compatibility weren’t a top priority.

That all changed in 1995 when Brendan Eich, inspired by Java, Self, and Scheme, created JavaScript while he was at Netscape Communications. The emergence of this new technology gave rise to the first frameworks and libraries and eliminated browser incompatibilities.

Over a decade later, frameworks such as MooTools, jQuery, HTML5, and AngularJS breathed new life into front-end technologies. Since then, there has been a new JavaScript framework a library released about every six months.

A recent study by Stack Overflow found that jQuery was considerably popular from 2009 to 2015 and accounted for 8% of new questions on the platform. However, the emergence of AngularJS (and later ReactJS) took the lead and dominated the mindshare of the Stack Overflow community.

In 2016, there was a shift from AngularJS to Angular (which also represented subsequent versions like Angular 2+) and developers raced to migrate to the latest popular framework offered by Google.

Stack Overflow’s findings suggest that Angular and React are clear front-runners when it comes to front-end development with Angular generating more traffic among C#, Java, and PHP developers and Facebook’s React attracting more NodeJS, Python, and Rails developers.

Where does Angular stand today?

If you look at the State of JavaScript 2017 report, React is far ahead with 13,669 of developers surveyed stating that they will use it again. Angular 1 came a distant third with 4,707 developers willing to use it again and Angular 2 came in fifth with 4,449 developers willing to use the framework in the future.

Javascript Frameworks over Time (Stack Overflow)

The study also found that as much as 12,175 developers were interested in learning VueJS while 6,072 developers were interested in learning Angular 2. However, 9,615 developers stated that they wouldn’t use Angular 1 ever again while another 10,657 developers had heard of Angular 2 but weren’t remotely interested in using it.

In Australia, about 8,143 verified business websites (with the highest concentration in New South Wales and Victoria) were built using Angular. In the United States, Angular had a much bigger market share with a whopping 451,330 business websites leveraging this technology.

If you look at the numbers by industry, retail and media industries tended to use Angular and React more than any other. This makes sense as their business model is focused on delivering rich client-side experiences to create more engaging user experiences.

In contrast, other sectors like government, healthcare, and education don’t seem to have much need for these types of frameworks. This might come down to the fact that their primary focus is database management and analytics, not front-end web development.

What’s the community is saying?

James Ferguson, Lead Front End Developer, at the Winning Group thinks Angular has become more stable now and can be used exclusively (with libraries and frameworks like rxjs, lodash and ngrx). “With the recent upgrade to Angular 5, we use the ahead of time compiler to save bundle size and increase performance. As the ecosystem matures, we find ourselves having to write less custom web-pack code, and being able to move closer to the defaults provided by the Angular client team.”

However, Adam Korczynski, Manager Delivery, ING prefers Polymer for day-to-day front-end development. “We decided to take that path in late 2015 when it was in version 0.4. We accepted the risk of adopting a platform which lacked maturity but aligned with our global strategic goals. Polymer comes with component isolation built-in and it’s standards-based, both of which appealed to us.”

For an enterprise like ING, “Angular wasn’t the right fit. We were aiming to consolidate a number of disparate frameworks used across the group in favour of a single library. Angular is ‘opinionated’ and like all opinions is subject to change with minimal consultation. While deciding on which direction to take, we watched the drawn-out and controversial development of Angular 2. It highlighted the pitfalls of opinionated frameworks. Polymer, on the other hand, wraps the web components standards and – we believe – is a safer bet that’s less likely to become obsolete over time.”

The case for Angular

Angular, maintained by Google and a supporting community of individuals and corporations have effectively addressed many of the development challenges related to single-page applications. By providing a framework for the client-side Model–View–Controller (MVC) and Model–View–View-Model (MVVM) architectures, they have also made development and testing of applications much easier.

While some front-end developers might disagree, the key advantage of Angular is its two-way data binding feature. In this scenario, both the Model and the View are synchronised. So when the Model changes, the View also changes enabling two-way data binding that can significantly reduce development time (because you don’t have to write any additional code).

Another benefit is Angular’s dependency injection feature. This defines how different pieces of code will interact with each other. Dependency also dictates how changes in one component will impact others. Typically, these dependencies are directly defined within the components themselves, so any change in dependency will require you to change the code as well. But with Angular, you can use the injectors that defined dependencies as external elements to decouple components from their dependencies. As a result, dependency injections make components highly reusable and much easier to test and manage.

Angular’s directives feature also allows HTML extensions to help assign behaviours to the Document Object Model. This enables developers to build rich and dynamic content with HTML. As Angular is still quite popular, front-end developers can also enjoy the support from a strong community of engineers who will help you find a robust solution for almost every imaginable problem.

The case against Angular

One of the barriers to Angular adoption is its steep learning curve. Since this technology is highly versatile, there’s more than one way to do things and that has been a source of confusion. However, with significant support from the community along with hundreds of tutorials, any conflict can be resolved quickly. Front-developers will also need to learn TypeScript before they can use Angular, so that will also add to its learning curve.

Newer versions of Angular were also completely rebuilt, so while they may still boast the same features, there’s no backward compatibility with older versions. It’s also known for not performing well when running complex SPAs and other dynamic applications because of their size.

James Ferguson agrees, “the key weaknesses of Angular compared to other frameworks are the bundle size and the community trust in the development process. The bundle size is larger than React and Vue because it’s a framework looking to provide a more complete solution. This is, however, being improved now by the Angular team, with new releases decreasing the bundle size and improving modularity and tree shaking. The Angular team also lost the trust of the community after they introduced radically breaking changes between AngularJS and Angular 2. The transitions from 2 to 4 and 5 have been greatly improved, but they still haven’t regained their earlier reputation. Compared to smaller frameworks though, developers can regain confidence knowing that this project backed by Google should retain some level of maintenance in the future.”

Should you be changing?

Frameworks like Angular, React, and Vue are all exceptional tools that help enhance user experiences and add value front-end development. Each has its own USPs that drive popularity and promise to play an important role for years to come. Even though React’s popularity might be soaring in recent months, it just doesn’t mean that Angular will soon be obsolete.

In my opinion, Angular’s potential decline is just a myth.

Facebook recently freed its React JavaScript library and its GraphQL query from its controversial BSD and Patents license and replaced it with the more welcoming MIT license. This groundbreaking event should get even more startups onboard with React going forward. However, Google’s increased focus on progressive web apps will ensure that Angular will hold its own for years to come.

Should you be changing from Angular to React or Vue or even Polymer in the near future?

The right answer to that question is relative to your project and business goals. Adam Korczynski suggests that you ask yourself the following questions. “Does the alternative framework address the reasons for leaving your current framework? Will it be difficult retraining or hiring developers? Is your codebase large or monolithic? If so, frameworks like Angular and React may be more appealing; if not, the cost of a mistake is smaller but the benefit of exploration can be invaluable.”

Written by Andrew Zola

February 15, 2018