repeat-array
v1.0.0
Published
repeats an input array or function n times into a new array
Downloads
108
Maintainers
Readme
repeat-array
repeats the contents of an Array
n
times.
how to install
npm i --save repeat-array
how to use
var repeat = require('repeat-array');
var arr = [1, 2, 3];
console.log(repeat(arr, 3));
// [1, 2, 3, 1, 2, 3, 1, 2, 3]