Interview Prep

Angular

250 questions across 24 categories

Interview Me →

50 of 50 questions

#CategoryQuestionAnswer★
1ArchitectureWhat is Angular's module system? Compare NgModules with the new standalone components API.
Click row to expand
2ArchitectureExplain Angular's dependency injection system. What are the different providers and injection tokens?
Click row to expand
3Change DetectionHow does Angular's change detection work? Explain Zone.js, OnPush strategy, and signals.
Click row to expand
4Change DetectionWhat is ChangeDetectorRef? Explain detach, detectChanges, and markForCheck in depth.
Click row to expand
5Change DetectionWhat is the async pipe? Why is it preferred over manual subscriptions for template bindings?
Click row to expand
6RxJSExplain the difference between switchMap, mergeMap, concatMap, and exhaustMap. When do you use each?
Click row to expand
7RxJSWhat are RxJS subjects? Compare Subject, BehaviorSubject, ReplaySubject, and AsyncSubject.
Click row to expand
8RxJSHow do you handle errors in RxJS? Explain catchError, retry, retryWhen, and error recovery patterns.
Click row to expand
9RxJSWhat are RxJS creation operators? Compare timer, interval, fromEvent, from, of, and defer.
Click row to expand
10RxJSHow do you prevent memory leaks from RxJS subscriptions? What patterns handle automatic unsubscription?
Click row to expand
11FormsCompare template-driven and reactive forms in Angular. When should you use each?
Click row to expand
12FormsHow do you implement custom validators and async validators in Angular reactive forms?
Click row to expand
13FormsWhat is ControlValueAccessor? How do you implement a custom form control?
Click row to expand
14RoutingHow does Angular Router work? Explain guards, resolvers, lazy loading, and route parameters.
Click row to expand
15RoutingWhat is Angular's preloading strategy? Compare NoPreloading, PreloadAllModules, and custom preloading.
Click row to expand
16ArchitectureWhat are Angular lifecycle hooks? In what order do they execute, and what are common mistakes?
Click row to expand
17ArchitectureWhat is the Angular HttpClient? Explain interceptors, error handling, and how to implement a retry interceptor.
Click row to expand
18PerformanceWhat is Angular's OnPush change detection strategy? How do you design components for maximum OnPush compatibility?
Click row to expand
19PerformanceWhat are Angular signals? Explain signal(), computed(), effect(), and how they integrate with components.
Click row to expand
20PerformanceHow do you implement lazy loading in Angular? Explain deferrable views (@defer) in Angular 17.
Click row to expand
21ArchitectureWhat are Angular directives? Compare attribute, structural, and component directives.
Click row to expand
22ArchitectureWhat are Angular pipes? When should you create custom pipes and how do you make them pure?
Click row to expand
23TestingHow do you unit test Angular components with TestBed? What should you mock and what should you use real instances of?
Click row to expand
24TestingHow do you test Angular services with HTTP calls using HttpClientTestingModule?
Click row to expand
25ArchitectureWhat is Angular CDK? What utilities does it provide for building custom UI components?
Click row to expand
26ArchitectureHow do you implement state management in Angular without a library? Explain the service-with-subject pattern and when to upgrade to NgRx.
Click row to expand
27PerformanceWhat is trackBy in *ngFor / @for? Why is it critical for list performance?
Click row to expand
28ArchitectureWhat is content projection in Angular? Explain ng-content, ng-template, ng-container, and multi-slot projection.
Click row to expand
29ArchitectureWhat is Angular's Zone.js? How does Zoneless Angular work and when would you use it?
Click row to expand
30RxJSWhat are RxJS multicasting operators? Compare share, shareReplay, publish, and multicast.
Click row to expand
31ArchitectureWhat is the difference between @ViewChild and @ContentChild? How do signals-based queries work in Angular 17?
Click row to expand
32ArchitectureWhat is the Angular control flow syntax (@if, @for, @switch)? How does it differ from structural directives?
Click row to expand
33TestingWhat is ComponentHarness in Angular CDK? How does it enable resilient component testing?
Click row to expand
34ArchitectureWhat is the Angular SSR (Server-Side Rendering) and the App Shell pattern? How do you configure Angular Universal?
Click row to expand
35ArchitectureWhat are Angular environments and how do you manage configuration for multiple environments?
Click row to expand
36PerformanceHow do you profile and optimize Angular application bundle size? What are the main causes of large bundles?
Click row to expand
37ArchitectureWhat is Angular's Dependency Injection hierarchical tree? Explain module injectors vs element injectors and their precedence.
Click row to expand
38TestingHow do you implement E2E testing for Angular with Playwright? What is the testing pyramid for Angular apps?
Click row to expand
39ArchitectureWhat is the Angular Router's NavigationExtras? Explain query params, fragments, state, and extras in navigation.
Click row to expand
40ArchitectureWhat are Angular animations? How do you use the Angular animation DSL and BrowserAnimationsModule?
Click row to expand
41RxJSWhat are higher-order Observables? How do you flatten them and why does nesting matter?
Click row to expand
42PerformanceHow do you implement server-sent events and WebSocket connections in Angular with RxJS?
Click row to expand
43FormsWhat is FormArray in Angular reactive forms? When and how do you use it for dynamic forms?
Click row to expand
44ArchitectureWhat is the Angular ElementRef and Renderer2? Why should you use Renderer2 instead of direct DOM manipulation?
Click row to expand
45ArchitectureExplain Angular's internationalization (i18n) support. How does $localize differ from pipe-based i18n libraries?
Click row to expand
46TestingHow do you test Angular directives? What's the difference between testing attribute vs structural directives?
Click row to expand
47ArchitectureWhat is NgRx Effects? How do you use them for side effects and compare them to RxJS-based service patterns?
Click row to expand
48FormsHow do you implement multi-step forms (wizard) in Angular? What state management approach works best?
Click row to expand
49PerformanceWhat is Angular Hydration? How does it prevent content flickering and improve Time to Interactive?
Click row to expand
50ArchitectureWhat are Angular micro-frontends? How do Webpack Module Federation and @angular-architects/module-federation enable them?
Click row to expand