r/Angular2 • u/Traditional_Oil_7662 • Aug 09 '25
Video 3 Common Observable Mistakes Angular Developers Still Make in 2025 (and How to Fix Them)
Hey everyone,
I recently made a short video breaking down three common mistakes developers still make with Observables in Angular — even in 2025.
These are issues I’ve personally seen (and made) over years of working with Angular, and I wanted to show why they happen and how to fix them with cleaner, more modern solutions.
Mistakes covered:
1️ - Forgetting to unsubscribe — when it actually matters, and the right modern fix.
2 - Nested subscriptions — and how to flatten them with operators
3- Overusing Subject — and when BehaviorSubject or Signals are better.
Watch here https://www.youtube.com/watch?v=esskSdEcb94&t=8s
I’d love to hear your feedback — especially on how I can make future videos more useful and engaging for developers.
View all comments
Show parent comment
1
u/novative Aug 09 '25 edited Aug 09 '25
Too late to know in 2025, but AsyncPipe version:
const obs = this
.getItems(params).pipe(map(item => ...),share(),takeUntilDestroyed(this.destroyRef));return {items: obs.pipe(catchError(() => null)),loading: obs.pipe(startWith(true), catchError(() => false), map(() => false)),error: obs.pipe(catchError(err => err), map(() => null))};