Loading

Quipoin Menu

Learn • Practice • Grow

Direction: Choose the correct option

Q1.

What is property binding in Angular?
A. Binding events
B. Binding component properties to HTML element properties using `[property]`
C. Two-way binding
D. String interpolation
Direction: Choose the correct option

Q2.

Which syntax is used for two-way data binding?
A. ()
B. [(ngModel)]
C. {{}}
D. []
Direction: Choose the correct option

Q3.

What does `[value]='name'` do?
A. Binds an event
B. Binds the `value` property of the element to the component's `name` property
C. Creates a two-way binding
D. Sets the value attribute to the string 'name'
Direction: Choose the correct option

Q4.

What is the difference between property binding and interpolation?
A. Property binding is for events, interpolation for text
B. Interpolation only works with strings
C. They are essentially the same for string values
D. Both A and C
Direction: Choose the correct option

Q5.

Which module is required to use `ngModel`?
A. FormsModule
B. HttpClientModule
C. ReactiveFormsModule
D. RouterModule
Direction: Choose the correct option

Q6.

What does `[attr.aria-label]='label'` do?
A. Binds to an event
B. Binds to a property
C. Binds to a class
D. Binds to an HTML attribute (aria-label)
Direction: Choose the correct option

Q7.

How do you bind to a CSS class conditionally?
A. [class]='active'
B. ngClass='active'
C. class.active='isActive'
D. [class.active]='isActive'
Direction: Choose the correct option

Q8.

What is the purpose of `[style.property]` binding?
A. To bind inline styles dynamically
B. To bind events
C. To bind CSS classes
D. To bind attributes
Direction: Choose the correct option

Q9.

What is one-time data binding?
A. Data that is static
B. Data that updates once
C. Data that doesn't update after initialization
D. Data that binds to one property
Direction: Choose the correct option

Q10.

Can you bind to custom component properties?
A. No, only native properties
B. Only with directives
C. Yes, using @Input decorator
D. Only with services