-
Notifications
You must be signed in to change notification settings - Fork 0
every
Subhajit Sahu edited this page Jun 17, 2020
·
16 revisions
Checks if all values satisfy a test. 🏃 📼 📦 🌔 📒
Similar: [some], [every].
entries.every(x, fn);
// x: entries
// fn: test function (v, k, x)
const entries = require('extra-entries');
var x = [['a', 1], ['b', 2], ['c', -3], ['d', -4]];
entries.every(x, v => v > 0);
// false
entries.every(x, v => v > -10);
// true