Library

AngularJS

by Jeremy Caney

Google AngularJS is a JavaScript framework based loosely on the popular model-view-controller design pattern. At a high-level, AngularJS makes it considerably easier for web developers to write sophisticated client-side applications by keeping data synchronized with the user interface. In addition, it includes a sophisticated "HTML compilation" model which allows custom controls to be wrapped as proprietary markup extensions, making it easier to implement and maintain complex user interfaces.

Strengths

The programming model of AngularJS is very elegant, and greatly simplifies the development of particular types of applications - and, in particular, single-page applications with multiple views which must be synchronized with server-side data via web services. AngularJS applications borrow from familiar traditional programming concepts, while flexibly integrating with many existing JavaScript libraries. AngularJS is also interface-agnostic: it does not ship with any controls, and can easily be integrated with many different UI frameworks (e.g., Bootstrap) or JavaScript libraries (e.g., jQuery and related plugins). 

Weaknesses

JavaScript frameworks like AngularJS must mitigate certain limitations of the JavaScript 5.0. These include a lack of promises, observability, modules, namespaces, etc. Because these must be implemented at the framework level, this limits how much interoperability and reusability is possible between frameworks; as a result, plugins written for AngularJS are largely incompatible with other frameworks, and vice versa. That said, many of these limitations will be mitigated with AngularJS 2.0, which uses newly introduced language features from JavaScript 6.0.

Usage

AngularJS is best applied for single-page AJAX-based applications, as an alternative to using a server-side preprocessor (e.g., ASP.NET, PHP). It is less effective as a stand-alone library for integrating dynamic features into an existing website. This also makes AngularJS a solid foundation for "hybrid" mobile apps, such as those to be distributed using Cordova (PhoneGap). As an alternative, Sencha ExtJS provides a more opinionated framework which is better suited for complex administration tools and line-of-business applications which may be willing to give up control over interface design in exchange for a comprehensive library of controls

BestPractices

When integrating with Bootstrap, use the UI Bootstrap directives for AngularJS.