@newdash/newdash
Version:
javascript/typescript utility library
23 lines (22 loc) • 646 B
TypeScript
/**
* This method is like `zip` except that it accepts an array of grouped
* elements and creates an array regrouping the elements to their pre-zip
* configuration.
*
* @since 5.3.0
* @category Array
* @param array The array of grouped elements to process.
* @returns Returns the new array of regrouped elements.
* @see unzipWith,zip,zipObject,zipObjectDeep,zipWith
* @example
*
* ```js
* const zipped = zip(['a', 'b'], [1, 2], [true, false])
* // => [['a', 1, true], ['b', 2, false]]
*
* unzip(zipped)
* // => [['a', 'b'], [1, 2], [true, false]]
* ```
*/
declare function unzip(array: any[][]): any[][];
export default unzip;