Type of input items.
Type of mapped output items.
The array to map.
Items per batch. 0 means “use the entire array as one batch”.
Must be a non-negative safe integer.
Async mapper invoked for each batch.
batch: A slice of arr (or the entire array when batch_size === 0).index: The starting index of batch within arr.A promise resolving to a flat array containing all mapped items.
Asynchronously maps an array in batches and concatenates the results.
batch_size > 0, the array is split into consecutive batches of up tobatch_sizeelements and processed sequentially.batch_size === 0, the entire array is passed as a single batch (withindex = 0).The mapping function
fnmay return:null/undefined, which is simply treated as an empty array ([]).