aboutsummaryrefslogtreecommitdiff
path: root/node_modules/repeat-element/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/repeat-element/index.js')
-rw-r--r--node_modules/repeat-element/index.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/node_modules/repeat-element/index.js b/node_modules/repeat-element/index.js
new file mode 100644
index 0000000..06a8d01
--- /dev/null
+++ b/node_modules/repeat-element/index.js
@@ -0,0 +1,18 @@
+/*!
+ * repeat-element <https://github.com/jonschlinkert/repeat-element>
+ *
+ * Copyright (c) 2015-present, Jon Schlinkert.
+ * Licensed under the MIT license.
+ */
+
+'use strict';
+
+module.exports = function repeat(ele, num) {
+ var arr = new Array(num);
+
+ for (var i = 0; i < num; i++) {
+ arr[i] = ele;
+ }
+
+ return arr;
+};