UNPKG

ramda

Version:

A practical functional library for JavaScript programmers.

18 lines 540 B
import _xfBase from "./_xfBase.js"; var XFilter = /*#__PURE__*/function () { function XFilter(f, xf) { this.xf = xf; this.f = f; } XFilter.prototype['@@transducer/init'] = _xfBase.init; XFilter.prototype['@@transducer/result'] = _xfBase.result; XFilter.prototype['@@transducer/step'] = function (result, input) { return this.f(input) ? this.xf['@@transducer/step'](result, input) : result; }; return XFilter; }(); export default function _xfilter(f) { return function (xf) { return new XFilter(f, xf); }; }