Angular · Middle · Question 70 of 75
What does toSignal(obs$, { initialValue: [] }) change compared to toSignal(obs$)?
- ✓Correct answer: The signal starts with
[]instead ofundefined, so its type doesn't includeundefined - 2It makes the Observable hot
- 3It unsubscribes after the first value
Explanation
For Observables that emit synchronously (like a BehaviorSubject), requireSync: true removes undefined without an initial value.