Free MuleSoft CONNECT Keynote & Expo Pass Available!

Register now+
Nav

divideBy

divideBy(Array<T>, Number): Array<Array<T>>

Divides an Array of items into sub arrays. .Transform


        
     
1
2
3
output application/json
---
[1, 2, 3, 4, 5] divideBy 2
Output

        
     
1
2
3
4
5
6
7
8
9
10
[
   [
     1,
     2
   ],
   [
     4,
     5
   ]
 ]