What is scope in AngularJS?

Technology CommunityCategory: AngularJSWhat is scope in AngularJS?
VietMX Staff asked 3 years ago

Scope is a JavaScript object that refers to the application model. It acts as a context for evaluating angular expressions. Basically, it acts as glue between controller and view.

Scopes are hierarchical in nature and follow the DOM structure of your AngularJS app. AngularJS has two scope objects: $rootScope and $scope.