Angular · Middle · Question 55 of 75

What does the scan operator do?

clicks$.pipe(scan((total) => total + 1, 0))

Explanation

reduce waits for completion; scan emits after every value, which suits counters or a reducer-like state stream.

Further reading

Problem with a question

Angular · Middle · question 55

Test yourself

Take the Angular · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz