Deck 2: AngularJS: Functions, Directives, and Events

ملء الشاشة (f)
exit full mode
سؤال
Which angular function is used to wrap a raw DOM element or HTML string as a jQuery element?

A)angular.element
B)angular.bootstrap
C)none
D)all
استخدم زر المسافة أو
up arrow
down arrow
لقلب البطاقة.
سؤال
Can '$scope' be injected while creating service using 'factory' method?

A)Yes
B)No
C)none
D)all
سؤال
AngularJS needs data in JSON format to populate its model.

A)true
B)false
C)none
D)all
سؤال
Scope act as glue between controller and view.

A)true
B)false
C)none
D)all
سؤال
AngularJS 1.0 was released in 2013.

A)True
B)False
C)none
D)all
سؤال
AngularJS applications are a mix of . . . . . .

A)HTML and PHP
B)HTML and CrossScript
C)HTML and AngularScript
D)HTML and JavaScript
سؤال
We need to tell AngularJS what part of our HTML page contains the AngularJS app. You do so by adding the . . . . attribute to the root HTML element of the AngularJS app.

A)ng-app
B)ag-app
C)js-app
D)aj-app
سؤال
There is a controller which takes single parameter. We call it . . . . . parameter.

A)$param
B)$control
C)$scope
D)$scont
سؤال
The . . . . . . directive is one of the most fundamental directives in AngujarJS. The . . . . . directive inserts the result of an expression into the HTML template.

A)Debug
B)Interpolation
C)Matching
D)Controller
سؤال
First the HTML document is loaded into the browser, and evaluated by the browser. At this time the AngularJS . . . . . . .

A)JavaScript file is loaded,
B)the angular global object is created,
C)your JavaScript which registers controller functions is executed,
D)all of above
سؤال
You cannot use AngularJS directives to tell AnguluarJS how to mix the data into the HTML template.

A)True
B)False
C)none
D)all
سؤال
If the data obtained from the model contains HTML elements, these are escaped before being inserted into the HTML template. The escaping means that the HTML is displayed as text, and not as HTML. This is done to prevent . . . .

A)SQL injection attacks
B)JS injection attacks
C)HTML injection attacks
D)Python injection attacks
سؤال
AngularJS can show or hide HTML depending on the state of data in the model. You do so using a set of AngularJS directives such as . . . . . . which are created specifically for that purpose.

A)ng-shown, ng-hidden
B)ng-show, ng-hide
C)nt-show, nt-hide
D)ng-shows, ng-hides
سؤال
The . . . . . directive is used if you want to add or remove HTML elements from the DOM based on data in the model.

A)ng-switch
B)ng-model
C)ng-Disabled
D)ng-Cloak
سؤال
Event binding can be defined . . . . . . . . .

A)by wrapping the event in (parenthesis)
B)by prefixing it with in
C)by wrapping the event in {curly brackets}
D)by prefixing it with on
سؤال
EventEmitter class acts both as an observer and observable.

A)True
B)False
C)none
D)all
سؤال
Events in Angular 2 behave like normal DOM events. They can bubble up but cannot propagate down.

A)True
B)False
C)none
D)all
سؤال
EventEmitter class's simple interface, which basically encompass two methods . . . . . . . . . can therefore be used to trigger custom events and listen to events as well, both synchronously or asynchronously.

A)exit()
B)superscript()
C)subscribe()
D)emit()
سؤال
Angular framework provides event binding using in-built event as well as custom event. Custom events are the EventEmitter instances. To create a custom event we need to create an instance of EventEmitter annotated by . . . . . . .

A)@Input()
B)@Get()
C)@Output()
D)@Set()
سؤال
EventEmitter class is used by directives and components to emit custom Events.

A)True
B)False
C)none
D)all
سؤال
@Output() myEvent = new EventEmitter();

A)Declares an output property that fires events that you cannot subscribe to with an event binding.
B)Declares an output property that fires events that you can subscribe to with an event binding.
C)Declares an output property that overrides events that you can subscribe to with an event binding.
D)Declares an output property that subscribes events that you can subscribe to with an event binding.
سؤال
. . . . . . . . need to be passed as a parameter in the event callback from the template to capture the event object.

A)$event.start
B)$events
C)$eventobj
D)$event
سؤال
Calling . . . . . . . . on the event prevents propagation.

A)stopEventPropagation
B)preventEventPropagation
C)stopPropagation
D)preventPropagation
سؤال
Events on child elements are propagated upwards, and hence event binding is also possible on a parent element.

A)True
B)False
C)none
D)all
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/24
auto play flashcards
العب
simple tutorial
ملء الشاشة (f)
exit full mode
Deck 2: AngularJS: Functions, Directives, and Events
1
Which angular function is used to wrap a raw DOM element or HTML string as a jQuery element?

A)angular.element
B)angular.bootstrap
C)none
D)all
angular.element
2
Can '$scope' be injected while creating service using 'factory' method?

A)Yes
B)No
C)none
D)all
No
3
AngularJS needs data in JSON format to populate its model.

A)true
B)false
C)none
D)all
true
4
Scope act as glue between controller and view.

A)true
B)false
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
5
AngularJS 1.0 was released in 2013.

A)True
B)False
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
6
AngularJS applications are a mix of . . . . . .

A)HTML and PHP
B)HTML and CrossScript
C)HTML and AngularScript
D)HTML and JavaScript
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
7
We need to tell AngularJS what part of our HTML page contains the AngularJS app. You do so by adding the . . . . attribute to the root HTML element of the AngularJS app.

A)ng-app
B)ag-app
C)js-app
D)aj-app
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
8
There is a controller which takes single parameter. We call it . . . . . parameter.

A)$param
B)$control
C)$scope
D)$scont
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
9
The . . . . . . directive is one of the most fundamental directives in AngujarJS. The . . . . . directive inserts the result of an expression into the HTML template.

A)Debug
B)Interpolation
C)Matching
D)Controller
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
10
First the HTML document is loaded into the browser, and evaluated by the browser. At this time the AngularJS . . . . . . .

A)JavaScript file is loaded,
B)the angular global object is created,
C)your JavaScript which registers controller functions is executed,
D)all of above
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
11
You cannot use AngularJS directives to tell AnguluarJS how to mix the data into the HTML template.

A)True
B)False
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
12
If the data obtained from the model contains HTML elements, these are escaped before being inserted into the HTML template. The escaping means that the HTML is displayed as text, and not as HTML. This is done to prevent . . . .

A)SQL injection attacks
B)JS injection attacks
C)HTML injection attacks
D)Python injection attacks
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
13
AngularJS can show or hide HTML depending on the state of data in the model. You do so using a set of AngularJS directives such as . . . . . . which are created specifically for that purpose.

A)ng-shown, ng-hidden
B)ng-show, ng-hide
C)nt-show, nt-hide
D)ng-shows, ng-hides
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
14
The . . . . . directive is used if you want to add or remove HTML elements from the DOM based on data in the model.

A)ng-switch
B)ng-model
C)ng-Disabled
D)ng-Cloak
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
15
Event binding can be defined . . . . . . . . .

A)by wrapping the event in (parenthesis)
B)by prefixing it with in
C)by wrapping the event in {curly brackets}
D)by prefixing it with on
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
16
EventEmitter class acts both as an observer and observable.

A)True
B)False
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
17
Events in Angular 2 behave like normal DOM events. They can bubble up but cannot propagate down.

A)True
B)False
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
18
EventEmitter class's simple interface, which basically encompass two methods . . . . . . . . . can therefore be used to trigger custom events and listen to events as well, both synchronously or asynchronously.

A)exit()
B)superscript()
C)subscribe()
D)emit()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
19
Angular framework provides event binding using in-built event as well as custom event. Custom events are the EventEmitter instances. To create a custom event we need to create an instance of EventEmitter annotated by . . . . . . .

A)@Input()
B)@Get()
C)@Output()
D)@Set()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
20
EventEmitter class is used by directives and components to emit custom Events.

A)True
B)False
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
21
@Output() myEvent = new EventEmitter();

A)Declares an output property that fires events that you cannot subscribe to with an event binding.
B)Declares an output property that fires events that you can subscribe to with an event binding.
C)Declares an output property that overrides events that you can subscribe to with an event binding.
D)Declares an output property that subscribes events that you can subscribe to with an event binding.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
22
. . . . . . . . need to be passed as a parameter in the event callback from the template to capture the event object.

A)$event.start
B)$events
C)$eventobj
D)$event
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
23
Calling . . . . . . . . on the event prevents propagation.

A)stopEventPropagation
B)preventEventPropagation
C)stopPropagation
D)preventPropagation
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
24
Events on child elements are propagated upwards, and hence event binding is also possible on a parent element.

A)True
B)False
C)none
D)all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.
فتح الحزمة
k this deck
locked card icon
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 24 في هذه المجموعة.