Answer the question
In order to leave comments, you need to log in
How to execute function first in combineLatest?
There are observable variables, they are combined in combineLatest. You need to execute the third-party observable function on the thread before the switchMap is executed.
Start With fails with error TypeError: undefined is not iterable (cannot read property Symbol(Symbol.iterator)
)
combineLatest([var1, var2]).pipe(
startWith(this.func),
switchMap(([var1, var2) => this.getCurrent(var1, var2)
)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question