• Split the given array in chunks.

    Type Parameters

    • T


    • arr: T[]

      Array to be split into chunks.

    • chunkSize: number

      Size of the chunks.

    Returns T[][]

    Two dimensional array with arrays of length chunkSize. The last subarray could be shorter.

    Copyright Ⓒ 2024 SAP SE or an SAP affiliate company. All rights reserved.