70 likes | 81 Views
In this PPT you are going to know What are the controllers in AngularJS.<br><br>https://nareshit.com/angularjs-online-training/
E N D
MVC To understand the concept of controller, I would suggest you start reading MVC. MVC is nothing but Model View Controller. Now every Angular Application is based on MVC structure.
Model : The application which has the business logic and data model, usually the application which is connected with database.
View: The HTML code that will be visible to the user afterwards.
Controller: The code which will call different functions to get the right data from model to the view .
Angular Specifically for an Angular app, every ng-app is assigned a controller. Whenever the said ng-app is started, its controller comes in action. The functionality of the page will then come from this controller. Controllers in Angular is to expose/bind data to our view via $scope, and to add functions to $scope that contain business logic to enhance view behavior. Presentation logic should remain within views and directives. Controllers will refresh data every time it gets refreshed on loading, unlike services it retains the data on consequent Refreshes.
Meet the Experts : https://nareshit.com/angularjs-online-training/