wishthis/node_modules/rxjs/dist/cjs/internal/operators/count.js
2022-04-07 09:06:43 +02:00

9 lines
No EOL
350 B
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.count = void 0;
var reduce_1 = require("./reduce");
function count(predicate) {
return reduce_1.reduce(function (total, value, i) { return (!predicate || predicate(value, i) ? total + 1 : total); }, 0);
}
exports.count = count;
//# sourceMappingURL=count.js.map