javascript - Combining streams with baconjs -


i have asynchronous events need combining. constructing array of n streams; each stream has onvalue function process returned data.

i have tried combining of streams 1 onvalues on top of onvalue, not called properly.

var streams = []  ... stream = bacon.fromcallback ....  stream.onvalue...( )  streams.push(stream)  ... bacon.onvalues(streams, f() { .... } ) 

what right way have function called when each stream has (unique) value... , when completed?

i assume job:

bacon.combineasarray(streams).onend(f) 

Comments

Popular posts from this blog

c# - HttpResponseMessage System.InvalidOperationException -

sql - Postgresql error: "failed to find conversion function from unknown to text" -