Socket
Socket
Sign inDemoInstall

repeat-element

Package Overview
Dependencies
0
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.0 to 1.1.0

16

index.js

@@ -10,8 +10,12 @@ /*!

module.exports = function repeat(ele, n) {
var res = [];
while (n--) {
res.push(ele);
module.exports = repeat;
function repeat(ele, num) {
var arr = new Array(num);
for (var i = 0; i < num; i++) {
arr[i] = ele;
}
return res;
};
return arr;
}
{
"name": "repeat-element",
"description": "Create an array by repeating the given string n times.",
"version": "1.0.0",
"version": "1.1.0",
"homepage": "https://github.com/jonschlinkert/repeat-element",

@@ -28,3 +28,10 @@ "author": {

},
"files": [
"index.js"
],
"devDependencies": {
"benchmarked": "^0.1.3",
"chalk": "^0.5.1",
"glob": "^4.3.5",
"minimist": "^1.1.0",
"mocha": "*"

@@ -31,0 +38,0 @@ },

@@ -50,2 +50,2 @@ # repeat-element [![NPM version](https://badge.fury.io/js/repeat-element.svg)](http://badge.fury.io/js/repeat-element)

_This file was generated by [verb](https://github.com/assemble/verb) on January 11, 2015._
_This file was generated by [verb](https://github.com/assemble/verb) on January 26, 2015._
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc