Posted 11/26/2025
Copilot often suggests using detectChanges() or markForCheck() as a quick fix for various problems. However, in most cases, these methods do not solve the root cause. The actual issue is usually an incorrect data flow between components or bad architecture. These methods should be used only in special situations — definitely not as a workaround for misunderstanding or overusing the OnPush change detection strategy.
A good analogy is calling GC.Collect() in C#: it should be a rare, special-case tool, not something you rely on every day.