1. Question:What is Scope? 

    Answer
    Scope is an object that refers to the application model. It is an execution context for expressions. Scopes are arranged in hierarchical structure which mimic the DOM structure of the application. Scopes can watch expressions and propagate events.

    1. Report
  2. Question:What is $rootScope? 

    Answer
    Scope is a special JavaScript object which plays the role of joining controller with the views. Scope contains the model data. In controllers, model data is accessed via $scope object. $rootScope is the parent of all of the scope variables.

    1. Report
Copyright © 2024. Powered by Intellect Software Ltd