Namespace: array

array

Source:
index.js

Methods


<static> arrayToObject(arrayOfObjects, keyGetter, valueGetter)

Convert an array into a k-v paired object.

Parameters:
Name Type Description
arrayOfObjects *
keyGetter *
valueGetter *
Source:
array/arrayToObject.js
Returns:
Type
Object

<static> insertBetween(arr, separator)

Insert a separator as element into an array.

Parameters:
Name Type Description
arr Array
separator *
Source:
array/insertBetween.js
Returns:

The newly inserted array

Type
Array

<static> zipAndFlat(arr1, arr2)

One-by-one merge two arrays into one
10x faster than lodash flatten and zip

Parameters:
Name Type Description
arr1 Array
arr2 Array
Source:
array/zipAndFlat.js
Returns:
Type
Array