The AngularJS MVC pattern implementation

AngularJS follows the MVC pattern of software engineering and encourages loose coupling between presentation, data, and logic components. However, in the AngularJS framework, we do not declare the model as in other MVC libraries such as Ember.js and Backbone.js.

In AngularJS, we declare the model within the controller, through the use of $scope. Let's check the MVC behavior inside AngularJS in the upcoming sections.

Model

AngularJS Model can be considered as a JavaScript object or a primitive JavaScript type such as string, number, boolean, or complex objects.

Synthesizing its definition, AngularJS Model is a JavaScript object inside controllers using $scope. The properties and behaviors that represent the ...

Get Learning Single-page Web Application Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.