Explain the use of @injectable()?
Answer / Ekta Dohrey
In AngularJS, @Injectable() is a decorator used to indicate that a class can be managed by Angular's dependency injection (DI) system. It marks a class as a service and makes it available for dependency injection. This allows you to easily manage the lifecycle of your services and make them testable.
| Is This Answer Correct ? | 0 Yes | 0 No |
How does lazy load work?
Is angular 2 mobile oriented?
Why this project is called "AngularJS"?
Is angular front or back end?
List the key components of angular 2?
What is the difference between an order and a directive?
Explain ng-include directive in angularjs?
When will nginit be called? How would you make use of ngoninit()?
What are the interview questions for angularjs?
Is typescript an oop?
What is difference between factory and service?
How to use {}, [], [] and [()] in angular2 template?