Angular interview questions

Want to become an expert in cracking Angular interview questions?

Start with practicing the questions below. Whether a question involves multiple choice or live coding, we will give you hints as you go and tell you if your answers are correct or incorrect.

After that, take our timed public Angular interview questions test.

To use our service for testing developers, purchase one of the paid plans for companies.


1. Component
Angular Components Public

Which of the following statements about components in Angular are correct?

Easy  
2min
Solve question

2. Animal Noise
Angular Expressions Public New

Consider the following component, which can be used to model an animal and the noise it makes.

import {Component, Input, Output} from '@angular/core';

@Component({
  selector: 'animal-noise',
  template: `
    <span>{{animal}}</span>
    <button (click)="makeNoise()">Make noise</button>
  `
})
export class AnimalNoise {
  @Input('animal') animal: string;
  @Input('noise') noise: string;

  makeNoise() {
    alert(`${this.noise}`);
  }
}

Select all the statements about the AnimalNoise component that are correct.

Easy  
3min
Solve question

3. Router Module
Angular Routing Public

Consider the following application module:

import { NgModule }             from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { HomeComponent }        from './home.component';
import { ItemDetailComponent }  from './item-detail.component';
const routes: Routes = [
    { path: '', redirectTo: '/home', pathMatch: 'full' },
    { path: 'home',  component: HomeComponent },
    { path: 'detail/:id', component: ItemDetailComponent, outlet: 'route1' }
];
@NgModule({
    imports: [ RouterModule.forRoot(routes) ],
    exports: [ RouterModule ]
})
export class AppRoutingModule {}

Which of the following statements about the routers behavior are correct?

Hard  
3min
Solve question

If you feel ready, take one of our timed public Angular interview questions tests:
  • Angular (quick test) ( Easy  /  Hard )
  • Angular and TypeScript (quick test) ( Easy )
Not exactly what you are looking for? Go to our For developers section.