Angular - Change DetectionWhy does Angular's Default change detection strategy run slower in large apps compared to OnPush?ABecause Default only checks components with changed inputsBBecause OnPush disables change detection entirelyCBecause Default checks every component every cycle, causing many unnecessary checksDBecause OnPush requires manual change detection callsCheck Answer
Step-by-Step SolutionSolution:Step 1: Compare Default and OnPush strategiesDefault runs change detection on all components every cycle; OnPush limits checks.Step 2: Understand performance impact in large appsChecking all components frequently causes slower performance in Default strategy.Final Answer:Because Default checks every component every cycle, causing many unnecessary checks -> Option CQuick Check:Default = many checks; OnPush = fewer checks [OK]Quick Trick: Default checks all components each cycle, slowing large apps [OK]Common Mistakes:MISTAKESThinking OnPush disables detectionBelieving Default checks only changed inputsAssuming OnPush needs manual calls
Master "Change Detection" in Angular9 interactive learning modes - each teaches the same concept differentlyLearnWhyDeepVisualTryChallengeProjectRecallPerf
More Angular Quizzes Angular Change Detection - Zone.js and automatic detection - Quiz 1easy Angular Change Detection - When to use OnPush - Quiz 5medium HTTP Client - Setting headers and params - Quiz 12easy Reactive Forms - Custom validators - Quiz 7medium Routing - Query parameters and fragments - Quiz 3easy RxJS Operators - debounceTime for input throttling - Quiz 6medium RxJS and Observables Fundamentals - Why observables matter in Angular - Quiz 5medium Services and Dependency Injection - Service-to-service injection - Quiz 7medium Services and Dependency Injection - How dependency injection works in Angular - Quiz 11easy Template-Driven Forms - Form validation with template attributes - Quiz 13medium