async function chunkMapAsync (arr, chunkSize, cb) {
  const resultChunks = []
  for (let chunk of chunkArray(arr, chunkSize)) {
    resultChunks.push(await Promise.all(chunk.map(cb)))
  }
  return resultChunks.flat()

}
Helper to run an async operation against an array in chunks
@example
var res = await chunkAsync(values, v => fetchAsync(v), 3) // chunks of 3s
@param {any[]} arr 
@param {Number} chunkSize 
@param {(value: any, index: number, array: any[]) => Promise<any>} cb 
@returns {Promise<any[]>}