Chapter 3. MVC and AngularJS

AngularJS presents a new and powerful way to develop web applications and websites—it has the power and functionality of conventional web frameworks, but with many advantages. AngularJS provides a way to build web apps and sites without the overhead normally associated with web frameworks.

Conventional web frameworks often tolerate server-side page scripting using PHP, Active Server Pages (ASP), and Java Server Pages (JSP). While server-side page scripting works sufficiently well on the server side, it does pose many maintenance issues for developers. But that is not the biggest issue with conventional web frameworks. Conventional web frameworks tend to run slower and be sluggish on mobile devices. And mobile users have a much lower tolerance for system delays and slow page loads than desktop users.

We must compare conventional web frameworks to AngularJS to understand the advantages that AngularJS presents. The next section will give you a clear understanding of the advantages of AngularJS over frameworks that you may have used in the past. With that understanding, we will be set to start building more maintainable applications in a better way.

The Old Way

Web MVC frameworks such as Apache Struts, Spring MVC, and the Zend Framework dominated the web development framework space for more than 15 years. Those same frameworks still dominate the space even today. There are some cases where web frameworks do present a better application design than more ...

Get Learning AngularJS now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.