Comparing version 0.4.0 to 0.4.1
27
index.js
"use strict"; | ||
var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); | ||
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); | ||
Object.defineProperty(exports, "__esModule", { | ||
value: true | ||
}); | ||
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } | ||
@@ -15,3 +11,3 @@ | ||
var Arey = exports.Arey = (function (_Array) { | ||
var Arey = function (_Array) { | ||
_inherits(Arey, _Array); | ||
@@ -22,3 +18,3 @@ | ||
return _possibleConstructorReturn(this, Object.getPrototypeOf(Arey).call(this, size)); | ||
return _possibleConstructorReturn(this, (Arey.__proto__ || Object.getPrototypeOf(Arey)).call(this, size)); | ||
} | ||
@@ -29,5 +25,7 @@ | ||
value: function of() { | ||
var _slice; | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { | ||
args[_key] = arguments[_key]; | ||
} | ||
return (_slice = this.slice).call.apply(_slice, arguments); | ||
return Array.prototype.slice.call(args); | ||
} | ||
@@ -40,6 +38,15 @@ }, { | ||
} | ||
}, { | ||
key: 'diff', | ||
value: function diff(arr1, arr2) { | ||
return arr1.filter(function (x) { | ||
return arr2.indexOf(x) == -1; | ||
}); | ||
} | ||
}]); | ||
return Arey; | ||
})(Array); | ||
}(Array); | ||
module.exports = Arey; | ||
{ | ||
"name": "arey", | ||
"version": "0.4.0", | ||
"version": "0.4.1", | ||
"description": "Experimental module that uses ES6 classes to extend `Array`", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -13,2 +13,3 @@ # arey | ||
Arey.isArray([1,2,3]) // true | ||
.diff([1,2,3], [3,4,5]) // [1,2] | ||
``` | ||
@@ -15,0 +16,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3372
38
19