I\'m looking for any alternatives to the below for creating a JavaScript array containing 1 through to N where N is only known at runt
1
N
the fastest way to fill an Array in v8 is:
Array
[...Array(5)].map((_,i) => i);
result will be: [0, 1, 2, 3, 4]
[0, 1, 2, 3, 4]