untilExists()

Creates a copy of an array with all of the consecutive items up to but not including the first value true-ish value.

This function is valid in v2.2.0 to v2.13.1. This function has been downloaded 23 times.

Parameters

{Array} array
Array or array-like object containing values that will be copied.
{boolean=} opt_fromEnd Optional, Default:false
Indicates that the values should be copied starting from the end, not from the beginning as normal.

Returns

{Array}
If opt_fromEnd is not given or is false-ish, an array of all of the consecutive false-ish values starting at the beginning of array will be returned. Otherwise an array of all of the consecutive false-ish values starting at the end of array will be returned.

Required Function

This function requires the following function which is included automatically:

  • whileExists()
    Creates a copy of an array with all of the consecutive items up to but not including the first value false-ish value.