Multiple Choice Questions - Angular2 Components
1. A component is a class decorated with some metadata and . . . . . . are functions that can modify a class.
2. Consider the statement "Every component must be declared in one and only one Angular module". Is it true or false?
3. . . . . . . . . . . . is a life cycle hook called by Angular2 to indicate that Angular is done creating the component.
4. Elements present inside the template of a component are called . . . . . . . children.
5. Some of the core properties that we required when creating Angular 2 components are
B) Templates & selectors
A) It is used to override the default change detection algorithm for a directive.
B) It is invoked on every check of your component’s view.
C) It is invoked when the view is completely initialised.
D) It is invoked every time the directive’s content is checked.
7. . . . . . . . . . are used to invoke events on the parent component from child components in the hierarchy of components.
8. The scope of the component travels through the chain of components. However, components that are defined in the . . . . . . . . . array aren’t injected or inherited by the child components in the hierarchical chain.
9. Components are basically directives with views but we cannot implement them by nesting/composing other directives and components.
10. Components conduct a provider lookup upwards because each component has its own built-in . . . . . . . , which is specific to it.
1) b, 2) a, 3) d, 4) c, 5) a,b,c, 6) a, 7) b, 8) d, 9) b, 10) d