Created
July 8, 2016 13:41
-
-
Save oliverlundquist/3e174e84b207a7a104de355eb46a8ebf to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var a = Rx.Observable.fromEvent(document, 'click') | |
| .flatMapLatest(function () { | |
| return Rx.Observable.defer(function () { | |
| return new Promise(function (resolve) { | |
| setTimeout(function () { resolve('hey'); }, 2000); | |
| }); | |
| }); | |
| }); | |
| var b = a.subscribe(function () { console.log(arguments[0]); }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment