Blog

How Angular 2 and Dart Breathe New Life Into Front-End Development

Have you ever played bullshit bingo at a very boring front-end developers conference? If not, here’s an instruction: all players are listening to a keynote presentation and each time they hear a speaker say React they all gulp down a drink. The one who’s bounced out of the conference first loses the game. Each time a speaker says Redux all players should have two drinks at once. The time will fly fast, that’s for sure!

Getting back to serious stuff, AngularJS used to be trendy some time ago enjoying a very high adoption rate amongst developers. This can be explained by the fact that after jQuery Angular was a real break-through in front-end development. But years passed by and Angular started lagging behind rookies that rushed into a web development space. As a result, it eventually yielded to React and Redux.

Angular became an outsider because approaches to and technologies of front-end development changed significantly and projects became overwhelmed with business intelligence and data analytics requirements. On the other hand, time of webpage responsiveness and speed of performance remained critical factors in any web or mobile development project. As such, many Angular fans and evangelists had no other choice but migrate to ReactJS that allowed for building lightweight and highly responsive web and mobile properties.

With Angular 2 this situation is changing, as it provides nearly the same features and capabilities as React and even outperforms React in certain KPIs. But will Angular 2 be able to regain its market dominance and breathe new life into front-end development now?

According to Intersog CTO, the chance is high indeed. Angular 2 is a far cry from its predecessor, there’s even no reverse compatibility between these two versions. As a matter of fact, Angular 1 was based on approaches that are no longer used in today’s software project management. One of such approaches is data binding, i.e. the process of establishing a connection between the application UI and business logic. In Angular 1 its deployment left a lot to be desired. It was much easier to deploy data binding using React. And such examples are many.

The team behind the AngularJS framework definitely learned their lessons from Angular 1 inconsistencies and restrictions and presented its major overhaul known as Angular 2. At Intersog, we migrated some of our custom projects and to-do apps to Angular 2, got first-hand experience with using the framework, and have never regretted this decision.

The first thing that impressed us in Angular 2 is the speed of code performance. It was much faster than in React. Of course, we cleaned and polished the code before migrating it from React to Angular 2, but the latter was still able to significantly accelerate our code performance. Second, time of development. It’s just fun to write a code using Angular 2! The framework provides full and comprehensive documentation. Code review is enough to understand things that are missing in the specs. A big plus is that Angular 2 is written in Typescript and transpiles to Dart. In JS, there’s a common issue - you want to use a particular feature from the library, but it’s not clear what arguments it has. It’s not covered in documentation and IDE prompts over 10 features. Angular 2 provides a perfect solution for this issue!

Are you looking to hire front-end developers for your software development project fast, cost-effectively and with no HR, IT and administrative hassle?
Let's talk now!

Angular 2 is evolving at a rapid pace and is being in a release candidate stage right now, check out GitHub for milestones. When we migrated some projects to Angular 2, we expected a lot of issues as a result of a framework change, but in fact we never faced a serious challenge. We keep tracking of the system updates and brace ourselves for them. We chose to migrate some projects from React to Angular 2 because we used Dart on them and had the following requirements for a view framework: rich features out of the box, modularity, speed of development and compatibility with our clients’ ecosystems. We had to move away from React because it didn’t meet our fundamental requirements, and namely:

  • In React, components can only interact with the help of pop-up callbacks and there’s no essence for events
  • No DI box which results in crutches such as High Order Components
  • No typing for description of components interfaces (can only be realized via propTypes and Flow)

To cut it short, React can do almost everything, it’s very scalable, but it’s lagging behind in terms of out-of-the-box resources. It was ineffective for some of our custom projects.

Angular 2 forbids a lot, but it also gives away a lot! For some of our projects it’s a perfect tool, because it’s easy to set up and configure, easy to learn and it also provides native support of Dart.

By the way, Google Adwords is based entirely on Angular 2 + Dart stack!

At Intersog, we normally use this stack on projects with the following features:

The project requires a long-term technical support from your team

If you’re confident the project will be closed 6 months later, feel free to use JS, PHP and Perl (or whatever frontend technology you know). However, if you know for sure that the project will be supported and maintained by a few generations of software developers going forward, try to use Dart + Angular 2 and those future developers will thank you for a self-documenting code you’ll leave.

The project requires a considerable scope of code

It’s all about framework support. In my opinion, Dart code is so simple that it can easily be read by a programmer who’s never seen it before. Having skills in C, Java and C# will be enough to understand Dart and how to write in it.

Your project requires a big team to execute

If you only have 1 to 3 persons on your team, it’s easy to work based on social agreements (e.g. “I’m gonna do this feature, ok?” “I’ve just fixed a bug and commented on a module, leave me alone for now!”). However, when your project requires a big team, you can’t work informally any more. And if there’s a lot of code to be handled, things will undoubtedly go messy. Angular 2 can help avoid this. Angular 2 + Dart is a perfect stack for teams that work on a project in an isolated environment.

In fact, Angular 2 features resemble a serious enterprise solution. It doesn’t mean you can’t build a robust and reliable software product with other means. Yet, both Angular 2 and Dart are tailored to work with a complex custom code laden with abundant logics, etc.

Comparing different frameworks, we normally compare ecosystems. Our CTO believes today’s Angular 2 has the following competitors besides React:

  • Aurelia - a relatively young framework created by a former Google employee who got disappointed with Angular 2 and decided to build his own library of components. While having a cool look, it feels as though it had been designed just out of spite.
  • Polymer - it’s a library of components rather than a standalone framework.

To conclude with, Angular 2 has a great advantage. On the one hand, it’s maintained and upgraded by an experienced team with a huge knowledge base and best practices. On the other hand, the framework isn’t yet overloaded with a reverse compatibility, out-of-date architecture solutions, and other components that are about to pass into oblivion. That’s why Angular 2 can take the best from existing libraries and breathe new life into front-end development.

And what’s your take on this?

Contact us to learn more

    Skill FilterGet in touch!

    Phone: +1 773 Show

    Email: [email protected]

    Vik is our Brand Journalist and Head of Online Marketing / PR with 11+ years of international experience in IT B2B. He's also a guest blog contributor to Business2community, SitePoint, Journal of mHealth, Wearable Valley and other IT portals. You can contact him directly on LinkedIn.
    Intersog does not engage with external agencies for recruitment purposes. Learn more about this here.