UrbanPro
true

Learn Angular.JS from the Best Tutors

  • Affordable fees
  • 1-1 or Group class
  • Flexible Timings
  • Verified Tutors

Search in

$rootScope in Angular JS

P
Prathamesh K.
29/10/2016 0 0

$rootScope refers to an object which is accessible from everywhere of the application. You can think $rootScope as global variable which can be accessible in all controllers, services, directives. The $rootScope object has a function called $new() that’s used to create child scopes.

Rootscope

Angular JS finds ng-app and therefore creates a $rootScope object. Next, while traversing the DOM, Angular JS encounters another ng-controller directive which points to “myController”. Now, it creates another child scope using $rootScope.$new() called $scope.

Injecting rootScope in a controller:

0 Dislike
Follow 0

Please Enter a comment

Submit

Other Lessons for You

AngularJS Basics- 1
This is my first blog.I am just explaining the basics of AngularJS and Sample application in an interesting way so that anyone can create an Angular application. Let’s see how we can create :) Angular.js...

Angular 4 Forms: Template Driven Approach
Angular Forms: Forms in Angular 4 can be designed on two approaches. As you can see below , we have a Template based design and the other being a Reactive based design. Here we will try to understand...

Javascript function
Q1.function f() { ... } var f = function() { ... };Which will work?Both will work. The difference here is that one is a named function ( function f() ) while the other is a variable equal to...

Learning a new technology
Each and every day new technologies are getting introduced. Its quite clear that to be part of the fast moving professional world you should be upto date with the cutting edge technologies in the market....
S

Saurav Singh

1 0
0

Top 6 Technology Trends for 2020
Technology has been evolving at a pace that the annual predictions about trends may seem to be outdated before they go live as a published blog post or article. The technology when evolves...
X

Looking for Angular.JS Classes?

The best tutors for Angular.JS Classes are on UrbanPro

  • Select the best Tutor
  • Book & Attend a Free Demo
  • Pay and start Learning

Learn Angular.JS with the Best Tutors

The best Tutors for Angular.JS Classes are on UrbanPro

This website uses cookies

We use cookies to improve user experience. Choose what cookies you allow us to use. You can read more about our Cookie Policy in our Privacy Policy

Accept All
Decline All

UrbanPro.com is India's largest network of most trusted tutors and institutes. Over 55 lakh students rely on UrbanPro.com, to fulfill their learning requirements across 1,000+ categories. Using UrbanPro.com, parents, and students can compare multiple Tutors and Institutes and choose the one that best suits their requirements. More than 7.5 lakh verified Tutors and Institutes are helping millions of students every day and growing their tutoring business on UrbanPro.com. Whether you are looking for a tutor to learn mathematics, a German language trainer to brush up your German language skills or an institute to upgrade your IT skills, we have got the best selection of Tutors and Training Institutes for you. Read more