We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Counts values which satisfy a test. 🏃 📼 📦 🌔 📒
Alternatives: count, countAs.
entries.count(x, ft); // x: a map // ft: test function (v, k, x)
const entries = require("extra-entries"); var x = [["a", 1], ["b", 1], ["c", 2], ["d", 2], ["e", 4]]; entries.count(x, v => v % 2 === 1); // 2 entries.count(x, v => v % 2 === 0); // 3