rxjsOperator: map / select


  • Rx.Observable.prototype.map(selector, [thisArg])
  • Rx.Observable.prototype.select(selector, [thisArg])


Parameter, TypeDetails
selector, Function or ObjectTransform function to apply to each source element or an element to yield. If selector is a function, it is called with the following information: 1. the value of the element, 2. the index of the element, 3. the Observable object being subscribed.
[thisArg], AnyObject to use as this when executing the predicate.


map and select are aliases.

They produce an observable sequence emitting one element every time the source observable emits an element.

If selector is not a function, its value is emitted for each source element.

If selector is a function, the emitted element is the result of running selector on the source element, and can possibly use its position.