@reactivex/ix-esnext-esm
Version:
The Interactive Extensions for JavaScript
1 lines • 1.7 kB
Source Map (JSON)
{"version":3,"sources":["add/iterable-operators/reduceright.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAYzD,MAAM,UAAU,gBAAgB,CAE9B,oBAA8F,EAC9F,IAAQ;IAER,OAAO,WAAW,CAChB,IAAI;IACJ,6CAA6C;IAC7C,OAAO,oBAAoB,KAAK,UAAU;QACxC,CAAC,CAAC,SAAS,CAAC,MAAM,GAAG,CAAC;YACpB,CAAC,CAAC,EAAE,UAAU,EAAE,oBAAoB,EAAE,MAAM,EAAE,IAAI,EAAE;YACpD,CAAC,CAAC,EAAE,UAAU,EAAE,oBAAoB,EAAE;QACxC,CAAC,CAAC,oBAAoB,CACzB,CAAC;AACJ,CAAC;AAED,SAAS,CAAC,SAAS,CAAC,WAAW,GAAG,gBAAgB,CAAC","file":"reduceright.js","sourcesContent":["import { IterableX } from '../../iterable/iterablex';\nimport { reduceRight } from '../../iterable/reduceright';\nimport { ReduceOptions } from '../../iterable/reduceoptions';\n\n/**\n * @ignore\n */\nexport function reduceRightProto<T, R = T>(this: IterableX<T>, options: ReduceOptions<T, R>): R;\nexport function reduceRightProto<T, R = T>(\n this: IterableX<T>,\n accumulator: (accumulator: R, current: T, index: number) => R,\n seed?: R\n): R;\nexport function reduceRightProto<T, R = T>(\n this: IterableX<T>,\n optionsOrAccumulator: ReduceOptions<T, R> | ((accumulator: R, current: T, index: number) => R),\n seed?: R\n): R {\n return reduceRight(\n this,\n // eslint-disable-next-line no-nested-ternary\n typeof optionsOrAccumulator === 'function'\n ? arguments.length > 1\n ? { 'callback': optionsOrAccumulator, 'seed': seed }\n : { 'callback': optionsOrAccumulator }\n : optionsOrAccumulator\n );\n}\n\nIterableX.prototype.reduceRight = reduceRightProto;\n\ndeclare module '../../iterable/iterablex' {\n interface IterableX<T> {\n reduceRight: typeof reduceRightProto;\n }\n}\n"]}