Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
27 lines (23 sloc) 589 Bytes

Indicates time passed since previous value emission

const { rxObserver } = require('api/v0.3');
const { interval, merge } = require('rxjs');
const { timeInterval, take, map } = require('rxjs/operators');

merge(
  interval(5),
  interval(7)
)
  .pipe(
    take(10),
    timeInterval(),
    map(({ interval }) => `+${interval}`)
  )
  .subscribe(rxObserver(''));
You can’t perform that action at this time.