every
signature: every(predicate: function, thisArg: any): Observable
every(predicate: function, thisArg: any): Observable
If all values pass predicate before completion emit true, else false.
Examples
Example 1: Some values false
( Stackblitz | jsBin | jsFiddle )
Example 2: All values true
( Stackblitz | jsBin | jsFiddle )
Example 3: Values arriving over time and completing stream prematurely due to every returning false
( Stackblitz )
Additional Resources
:newspaper: - Official docs
:file_folder: Source Code: https://github.com/ReactiveX/rxjs/blob/master/src/internal/operators/every.ts
Last updated