What is the difference between $scope and scope?
Answer Posted / ankush
- The $ in "$scope" indicates that the scope value is being injected into the current context. $scope is a service provided by $scopeProvider. You can inject it into controllers, directives or other services using Angular's built-in dependency injector:
- scope could be anything, it's a function parameter name
function link( scope, element, attributes ) {
// Only scope
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Does bootstrap require jquery?
How many scopes can an application have?
What is difference between ng bind and expression?
what is the difference between one-way binding and two-way binding in angularjs?
How to get user input from a template reference variable?
Differentiate between @injectable() vs. @Inject()?
How is angularjs compiled?
What angular js routes does?
Why is typescript used in angular?
How to catch and log specific angular errors in your app?
Is angular 2 object oriented?
What are the new features of angular 2?
What is router state in angular 2?
What is the difference between a module’s forroot() and fairchild() methods and why do you need it?
What is injectors?