core-js-pure
Advanced tools
Comparing version 3.20.2 to 3.20.3
@@ -0,9 +1,10 @@ | ||
var NATIVE_BIND = require('../internals/function-bind-native'); | ||
var FunctionPrototype = Function.prototype; | ||
var apply = FunctionPrototype.apply; | ||
var bind = FunctionPrototype.bind; | ||
var call = FunctionPrototype.call; | ||
// eslint-disable-next-line es/no-reflect -- safe | ||
module.exports = typeof Reflect == 'object' && Reflect.apply || (bind ? call.bind(apply) : function () { | ||
module.exports = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call.bind(apply) : function () { | ||
return call.apply(apply, arguments); | ||
}); |
var uncurryThis = require('../internals/function-uncurry-this'); | ||
var aCallable = require('../internals/a-callable'); | ||
var NATIVE_BIND = require('../internals/function-bind-native'); | ||
@@ -9,5 +10,5 @@ var bind = uncurryThis(uncurryThis.bind); | ||
aCallable(fn); | ||
return that === undefined ? fn : bind ? bind(fn, that) : function (/* ...args */) { | ||
return that === undefined ? fn : NATIVE_BIND ? bind(fn, that) : function (/* ...args */) { | ||
return fn.apply(that, arguments); | ||
}; | ||
}; |
@@ -8,2 +8,3 @@ 'use strict'; | ||
var arraySlice = require('../internals/array-slice'); | ||
var NATIVE_BIND = require('../internals/function-bind-native'); | ||
@@ -24,3 +25,3 @@ var Function = global.Function; | ||
// https://tc39.es/ecma262/#sec-function.prototype.bind | ||
module.exports = Function.bind || function bind(that /* , ...args */) { | ||
module.exports = NATIVE_BIND ? Function.bind : function bind(that /* , ...args */) { | ||
var F = aCallable(this); | ||
@@ -27,0 +28,0 @@ var Prototype = F.prototype; |
@@ -0,5 +1,7 @@ | ||
var NATIVE_BIND = require('../internals/function-bind-native'); | ||
var call = Function.prototype.call; | ||
module.exports = call.bind ? call.bind(call) : function () { | ||
module.exports = NATIVE_BIND ? call.bind(call) : function () { | ||
return call.apply(call, arguments); | ||
}; |
@@ -0,7 +1,9 @@ | ||
var NATIVE_BIND = require('../internals/function-bind-native'); | ||
var FunctionPrototype = Function.prototype; | ||
var bind = FunctionPrototype.bind; | ||
var call = FunctionPrototype.call; | ||
var uncurryThis = bind && bind.bind(call, call); | ||
var uncurryThis = NATIVE_BIND && bind.bind(call, call); | ||
module.exports = bind ? function (fn) { | ||
module.exports = NATIVE_BIND ? function (fn) { | ||
return fn && uncurryThis(fn); | ||
@@ -8,0 +10,0 @@ } : function (fn) { |
@@ -5,3 +5,3 @@ var DESCRIPTORS = require('../internals/descriptors'); | ||
// Thank's IE8 for his funny defineProperty | ||
// Thanks to IE8 for its funny defineProperty | ||
module.exports = !DESCRIPTORS && !fails(function () { | ||
@@ -8,0 +8,0 @@ // eslint-disable-next-line es/no-object-defineproperty -- required for testing |
@@ -7,5 +7,7 @@ var IS_PURE = require('../internals/is-pure'); | ||
})('versions', []).push({ | ||
version: '3.20.2', | ||
version: '3.20.3', | ||
mode: IS_PURE ? 'pure' : 'global', | ||
copyright: '© 2022 Denis Pushkarev (zloirock.ru)' | ||
copyright: '© 2014-2022 Denis Pushkarev (zloirock.ru)', | ||
license: 'https://github.com/zloirock/core-js/blob/v3.20.3/LICENSE', | ||
source: 'https://github.com/zloirock/core-js' | ||
}); |
@@ -6,4 +6,4 @@ var $ = require('../internals/export'); | ||
// https://tc39.es/ecma262/#sec-function.prototype.bind | ||
$({ target: 'Function', proto: true }, { | ||
$({ target: 'Function', proto: true, forced: Function.bind !== bind }, { | ||
bind: bind | ||
}); |
@@ -19,2 +19,3 @@ var IS_PURE = require('../internals/is-pure'); | ||
var lengthOfArrayLike = require('../internals/length-of-array-like'); | ||
var validateArgumentsLength = require('../internals/validate-arguments-length'); | ||
var regExpFlags = require('../internals/regexp-flags'); | ||
@@ -451,3 +452,3 @@ var ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable'); | ||
structuredClone: function structuredClone(value /* , { transfer } */) { | ||
var options = arguments.length > 1 ? anObject(arguments[1]) : undefined; | ||
var options = validateArgumentsLength(arguments.length, 1) > 1 ? anObject(arguments[1]) : undefined; | ||
var transfer = options ? options.transfer : undefined; | ||
@@ -454,0 +455,0 @@ var map; |
@@ -27,2 +27,3 @@ 'use strict'; | ||
var getIteratorMethod = require('../internals/get-iterator-method'); | ||
var validateArgumentsLength = require('../internals/validate-arguments-length'); | ||
var wellKnownSymbol = require('../internals/well-known-symbol'); | ||
@@ -103,6 +104,2 @@ var arraySort = require('../internals/array-sort'); | ||
var validateArgumentsLength = function (passed, required) { | ||
if (passed < required) throw TypeError('Not enough arguments'); | ||
}; | ||
var URLSearchParamsIterator = createIteratorConstructor(function Iterator(params, kind) { | ||
@@ -109,0 +106,0 @@ setInternalState(this, { |
{ | ||
"name": "core-js-pure", | ||
"description": "Standard library", | ||
"version": "3.20.2", | ||
"version": "3.20.3", | ||
"repository": { | ||
@@ -57,3 +57,3 @@ "type": "git", | ||
}, | ||
"gitHead": "da1bf15799afc93d4985392a5d1ce5468db1bdd8" | ||
"gitHead": "4bcdaf8646f4e60bab9ac182b06803ebd230568c" | ||
} |
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
812892
2384
19307