Rx.Observable.prototype.takeLast(count)

takeLast.n

Returns a specified number of contiguous elements from the end of an observable sequence, using an optional scheduler to drain the queue.

This operator accumulates a buffer with a length enough to store elements count elements. Upon completion of the source sequence, this buffer is drained on the result sequence. This causes the elements to be delayed.

参数

  1. count (Number): Number of elements to bypass at the end of the source sequence.

返回值

(Observable): An observable sequence containing the source sequence elements except for the bypassed ones at the end.