Right, time to return to the mindfuck that is refactoring callbacks into promises in an app with a deep call stack.
#nodehedidnt
@mindcrash …as the sync-style nature actually makes up for any loss of intent in (e.g.) map/reduce
-
-
@aral (or a proper map/reduce: sequence.map(function(item){ ...}).reduce(function(acc, item){...}, seed).subscribe(...) )Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
@aral Also don't forget it's really easy to convert futures (or promises in JS speak) to observables and back again if you need that :)Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
@aral And anything you can do with sequences in FP is pretty much supported: https://github.com/Reactive-Extensions/RxJS/blob/master/doc/api/core/observable.md … -
@mindcrash@aral exactly, if you can do it with Array#extras, you can do it with async sequences -
@mindcrash@aral and best of all, you don't have to worry about the error propogation, and you can easily retry like obs.retry(3)
End of conversation
New conversation -
-
-
@aral loss of intent? sequence.filter(function(item) { ... }).map(function(item){ ... }).subscribe(...) (off the top of my head)Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.