RxJS 5 Playground
by Bhesh Gurung
HTML
<script src="https://unpkg.com/@reactivex/[email protected]/dist/global/Rx.js"></script>
JavaScript
console.clear();
var intervalSource = Rx.Observable.interval(1000);
var sub = intervalSource
.finally(() => console.log('well, crap...'))
.subscribe(nums => console.log(nums));
setTimeout(() => sub.unsubscribe(), 10000)