angular - Zip for every output -


i have 2 observables of type boolean . want zip them end result true if either of them true.

rx.observable.zip(firstbooleansource$, secondbooleansource$)     .map((results: boolean[]) => results.some( (result:boolean)=>result))     .subscribe(( status: boolean)=> console.log(status)); 

..

----false----------- ----false---true---- 

will result in

----false----  

expecting:

----false----true---- 

you need combinelatest operator combines values can map correct result


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -