Top 150+ Solved Angular-JS MCQ Questions Answer
Q. What are various possible prefixes such as 'ng-' using which Angular directives (forexample, ng-app) can be defined?
a. 'ng-', 'data-ng-', 'ng:'
b. 'ng-'
c. 'ng-', 'data-ng-', 'ng:', 'x-ng-'
d. 'ng-', 'data-ng-','x-ng-'
Q. What are various possible ways in which angular application can be initialized?
a. On an element, one could either put simply the attribute such as (ng-app, data-ng-app, ng:app, x-ng-app)
b. Put the named attribute such as (ng-app='demoApp')
c. Both of the above
d. none
Q. Can multiple angular applications be bootstrapped using same element??
a. Yes
b. No. An error is thrown such as 'App Already Bootstrapped with this Element'
c. none
d. all
Q. At framework level, how does Angular retrieve the matching elements for processing?
a. Makes use of jqLite(element) function.
b. If jQuery is used, jQuery(element) is used by way of assigning jQuery to jqLite variable
c. Both of the above
d. None of the above
Q. Which API need to be invoked on the rootScope service to get the child scopes?
a. new
b. $new
c. none
d. all
Q. What angular function is used to manually start up an angular application?
a. angular.bootstrap
b. angular.element
c. angular.copy
d. None of the above
Q. Which angular function is used to wrap a raw DOM element or HTML string as a jQueryelement?
a. angular.element
b. angular.bootstrap
c. none
d. all
Q. Can '$scope' be injected while creating service using 'factory' method?
a. Yes
b. No
c. none
d. all