Angular JS

The flashcards below were created by user caldreaming on FreezingBlue Flashcards.

  1. What are views in Angular JS?
    • Views render the user interface:
    •  * Contain HTML and CSS
    •  * Bind to data provided by a
    • controller via the $scope object
    •  * Use directives to enhance HTML
    • and render data
  2. Describe what 'scope' is in Angular JS;
    Image Upload
  3. What AngularJS directive is used to bind data?
    Image Upload
  4. In what year was AngularJS version 1 released?
    2012
  5. AngularJS is a JavaScript framework. It can be added to an HTML page with a _______ tag.

    A) <style>
    B) <script>
    C) <body>
    D) <a href>
    B) <script>
    (this multiple choice question has been scrambled)
  6. The _______ directive binds the value of HTML controls (input, select, textarea) to application data.

    A) ng-model
    B) ng-bind
    C) ng-app
    A) ng-model
    (this multiple choice question has been scrambled)
  7. The _________ directive defines an AngularJS application.

    A) ng-model
    B) ng-app
    C) ng-bind
    B) ng-app
    (this multiple choice question has been scrambled)
  8. The ________ directive binds application data to the HTML view.

    A) ng-bind
    B) ng-app
    C) ng-model
    A) ng-bind
    (this multiple choice question has been scrambled)
  9. The _______ directive tells AngularJS that the <div> element is the "owner" of an AngularJS application.

    A) ng-model
    B) ng-bind
    C) ng-app
    C) ng-app

    The ng-app directive tells AngularJS that the <div> element is the "owner" of an AngularJS application.
    (this multiple choice question has been scrambled)
  10. The _______ directive binds the value of the input field to the application variable name.

    A) ng-model
    B) ng-bind
    C) ng-app
    A) ng-model

    The ng-model directive binds the value of the input field to the application variable name.
    (this multiple choice question has been scrambled)
  11. The ______ directive binds the innerHTML of the <p> element to the application variable name.

    <div ng-app=""> 
        <p>Name: <input type="text" ng-model="name"></p> 
        <p ng-bind="name"></p>
    </div>

    A) ng-model
    B) ng-bind
    C) ng-app
    B) ng-bind

    The ng-bind directive binds the innerHTML of the <p> element to the application variable name.
    (this multiple choice question has been scrambled)
  12. The ______ directive initialize AngularJS application variables.

    <div ng-app="" ng-init="firstName='John'">
         <p>The name is <span ng-bind="firstName"></span></p>
    </div>
    ng-init

    The ng-init directive initialize AngularJS application variables.
  13. AngularJS _________ define applications:

    AngularJS Modulevar app = angular.module('myApp', []);

    A) Controllers
    B) Directives
    C) Modules
    C) Modules

    AngularJS modules define applications.
    (this multiple choice question has been scrambled)
  14. AngularJS controllers control applications:

    AngularJS Controllerapp.controller('myCtrl', function($scope) {   
         $scope.firstName= "John";      
         $scope.lastName= "Doe";
    });

    A) Directives
    B) Modules
    C) Controllers
    C) Controllers

    AngularJS controllers control applications.
    (this multiple choice question has been scrambled)
  15. T/F:  AngularJS expressions are much like JavaScript expressions: They can contain literals, operators, and variables.

    A) True
    B) False
    A) True

    AngularJS expressions are much like JavaScript expressions: They can contain literals, operators, and variables.

    Example {{ 5 + 5 }} or {{ firstName + " " + lastName }}
  16. T/F:  Like JavaScript expressions, AngularJS expressions cannot be written inside HTML.

    A) True
    B) False
    B) False

    Unlike JavaScript expressions, AngularJS expressions can be written inside HTML.
  17. T/F:  AngularJS expressions do not support conditionals, loops, and exceptions, while JavaScript expressions do.

    A) True
    B) False
    A) True

    AngularJS expressions do not support conditionals, loops, and exceptions, while JavaScript expressions do.
  18. T/F: Like JavaScript expressions, AngularJS expressions cannot contain literals, operators, and variables.

    A) True
    B) False
    B) False

    Like JavaScript expressions, AngularJS expressions CAN contain literals, operators, and variables.
  19. T/F: AngularJS expressions support filters, while JavaScript expressions do not.

    A) True
    B) False
    A) True

    AngularJS expressions support filters, while JavaScript expressions do not.
  20. Review Point

    AngularJS Modules
    • An AngularJS module defines an application.
    • The module is a container for the different parts of an application.
    • The module is a container for the application controllers.
    • Controllers always belong to a module.
  21. A module is created by using the AngularJS function _________________.
    angular.module

    Example:

    • <div ng-app="myApp">...</div>
    •      <script>
    •           var app = angular.module("myApp", []); 
    •      </script>
  22. What is an Angular directive and what is it used for?
    AngularJS directives are extended HTML attributes with the prefix ng- . The ng-app directive initializes an AngularJS application. The ng-init directive initializes application data. The ng-model directive binds the value of HTML controls (input, select, textarea) to application data.
Author:
caldreaming
ID:
314497
Card Set:
Angular JS
Updated:
2016-02-15 15:48:45
Tags:
angular js programming language mvc animation module view controller software development
Folders:

Description:
Angular JS Study
Show Answers: