MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / takeWhile

Function takeWhile

lib/web/jshint.js:7110–7114  ·  view source on GitHub ↗

* Creates a slice of `array` with elements taken from the beginning. Elements * are taken until `predicate` returns falsey. The predicate is bound to * `thisArg` and invoked with three arguments: (value, index, array). * * If a property name is provided for `predicate` the create

(array, predicate, thisArg)

Source from the content-addressed store, hash-verified

7108 * // => []
7109 */
7110 function takeWhile(array, predicate, thisArg) {
7111 return (array && array.length)
7112 ? baseWhile(array, getCallback(predicate, thisArg, 3))
7113 : [];
7114 }
7115
7116 /**
7117 * Creates an array of unique values, in order, of the provided arrays using

Callers

nothing calls this directly

Calls 2

baseWhileFunction · 0.85
getCallbackFunction · 0.85

Tested by

no test coverage detected