David has created two component AppComponent and HelloComponent and rendered the components in index.html as shown below:


<body>
<app-root></app-root>
<app-hello></app-hello>
</body>

The app module contains the below code:


@NgModule({
declarations: [
AppComponent,
HelloComponent
],
imports: [
BrowserModule,
AppRoutingModule
],
providers: [],
bootstrap: [AppComponent]
})

When the application is rendered on the browser only App Component is displayed. What is the reason for Hello Component not rendered?

Two components cannot be provided in index.html file

Hello component is not added within declarations section

Hello component is not added to the bootstrap section

Hello component is not added in imports section

Correct Option - c

To get all Infosys Certified Angular Web Developer Exam questions Join Group https://bit.ly/infy_premium_group

We're passionate about offering best placement materials and courses!! A one stop place for Placement Materials. We daily post Offcampus updates and Placement Materials.

Qtr No. 213, New Town Yehlanka Indore 454775

admin@prepflix.in