Join Examsbook
808 0

Q: What is factory method in AngularJS ?

  • 1
    It generates the facts and figures
  • 2
    It is used to create the service
  • 3
    It is used to calculate the factorial of a number
  • 4
    All the above
  • Show AnswerHide Answer
  • Workspace

Answer : 2. "It is used to create the service"
Explanation :

Answer: B) It is used to create the service Explanation: In general, Services are Javscript functions and are responsible to do a specific tasks. Factories implements module pattern in which we use a factory method to generate an object which is use for building models. It's syntax ismodule.factory('factoryName', function);

Are you sure

  Report Error

Please Enter Message
Error Reported Successfully