Is there a way to add a timer to distinctUntilChanged?
In rxjs 6
of(1, 2, 3, 3, 5, 6)
.pipe(distinctUntilChanged)
.subscribe(x => console.log(x)
My question is, is there a way to add a timer so that repeated values will emit if they fall outside the time range but will be ignored if they fall within the time range.
Like if the say the timer is set to 1000 (1s), in this case interval(1000) and a repeated value is emitted within the 1s it will be ignore but if after the interval (1s) it should be allowed through. I hope am making sense here
Also if there's a better way to do it without distinctUntilChanged i will gladly welcome that.
Thanks in advance