MCPcopy Index your code
hub / github.com/jashkenas/underscore / every

Function every

underscore-node-f.cjs:1430–1439  ·  view source on GitHub ↗
(obj, predicate, context)

Source from the content-addressed store, hash-verified

1428
1429// Determine whether all of the elements pass a truth test.
1430function every(obj, predicate, context) {
1431 predicate = cb(predicate, context);
1432 var _keys = !isArrayLike(obj) && keys(obj),
1433 length = (_keys || obj).length;
1434 for (var index = 0; index < length; index++) {
1435 var currentKey = _keys ? _keys[index] : index;
1436 if (!predicate(obj[currentKey], currentKey, obj)) return false;
1437 }
1438 return true;
1439}
1440
1441// Determine if at least one element in the object passes a truth test.
1442function some(obj, predicate, context) {

Callers

nothing calls this directly

Calls 3

predicateFunction · 0.85
cbFunction · 0.70
keysFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…