AngularJS Online Quiz


Advertisements

Following quiz provides Multiple Choice Questions (MCQs) related to AngularJS Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Answer : C

Explaination

ng-model directive binds the values of AngularJS application data to HTML input controls. It creates a model variable which can be used with the html page and within the container control( for example, div) having ng-app directive.

Q 3 - AngularJS expressions behave in same way as ng-bind directives.

A - false

B - true

Answer : B

Explaination

AngularJS expressions behave in same way as ng-bind directives.

Answer : C

Explaination

ng-show directive shows/hides a given control.

Q 5 - $rootScope is the parent of all of the scope variables.

A - true

B - false

Answer : A

Explaination

$rootScope is the parent of all of the scope variables.

Q 6 - Using service method, we define a service and then assign method to it.

A - true

B - false

Answer : A

Explaination

Using service method, we define a service and then assign method to it.

Q 7 - On which of the following types of component can we create a custom directive?

A - Element directives

B - Attribute

C - CSS

D - All of the above.

Answer : D

Explaination

AngularJS provides support to create custom directives for following type of elements.

  • Element directives - Directive activates when a matching element is encountered.

  • Attribute - Directive activates when a matching attribute is encountered.

  • CSS - Directive activates when a matching css style is encountered.

  • Comment - Directive activates when a matching comment is encountered.

Q 8 - ng-model binds the values of AngularJS application data to HTML input controls.

A - true

B - false

Answer : A

Explaination

ng-model binds the values of AngularJS application data to HTML input controls.

Q 9 - ng-init directive can be used to put values to the variables to be used in the application.

A - true

B - false

Answer : A

Explaination

ng-init directive can be used to put values to the variables to be used in the application.

Q 10 - orderby filter is applied to an expression using pipe character.

A - true

B - false

Answer : A

Explaination

orderby filter is applied to an expression using pipe character.

angularjs_questions_answers.htm
Advertisements