Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

core-js-pure

Package Overview
Dependencies
Maintainers
1
Versions
154
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

core-js-pure - npm Package Compare versions

Comparing version 3.27.1 to 3.27.2

internals/error-stack-install.js

25

internals/async-iterator-create-proxy.js

@@ -18,2 +18,3 @@ 'use strict';

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var ASYNC_ITERATOR_HELPER = 'AsyncIteratorHelper';

@@ -23,10 +24,6 @@ var WRAP_FOR_VALID_ASYNC_ITERATOR = 'WrapForValidAsyncIterator';

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var createAsyncIteratorProxyPrototype = function (IS_ITERATOR) {
var IS_GENERATOR = !IS_ITERATOR;
var ASYNC_ITERATOR_PROXY = IS_ITERATOR ? WRAP_FOR_VALID_ASYNC_ITERATOR : ASYNC_ITERATOR_HELPER;
var getInternalState = InternalStateModule.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ASYNC_ITERATOR : ASYNC_ITERATOR_HELPER);
var getInternalState = InternalStateModule.getterFor(ASYNC_ITERATOR_PROXY);
var getStateOrEarlyExit = function (that) {

@@ -60,3 +57,3 @@ var stateCompletion = perform(function () {

var AsyncIteratorProxyPrototype = defineBuiltIns(create(AsyncIteratorPrototype), {
return defineBuiltIns(create(AsyncIteratorPrototype), {
next: function next() {

@@ -88,3 +85,3 @@ var stateCompletion = getStateOrEarlyExit(this);

if (state.inner) try {
iteratorClose(state.inner.iterator, 'return');
iteratorClose(state.inner.iterator, 'normal');
} catch (error) {

@@ -110,16 +107,10 @@ return iteratorClose(iterator, 'throw', error);

});
if (IS_GENERATOR) {
createNonEnumerableProperty(AsyncIteratorProxyPrototype, TO_STRING_TAG, 'Async Iterator Helper');
}
return AsyncIteratorProxyPrototype;
};
var WrapForValidAsyncIteratorPrototype = createAsyncIteratorProxyPrototype(true);
var AsyncIteratorHelperPrototype = createAsyncIteratorProxyPrototype(false);
var WrapForValidAsyncIteratorPrototype = createAsyncIteratorProxyPrototype(true);
createNonEnumerableProperty(AsyncIteratorHelperPrototype, TO_STRING_TAG, 'Async Iterator Helper');
module.exports = function (nextHandler, IS_ITERATOR) {
var ASYNC_ITERATOR_PROXY = IS_ITERATOR ? WRAP_FOR_VALID_ASYNC_ITERATOR : ASYNC_ITERATOR_HELPER;
var AsyncIteratorProxy = function AsyncIterator(record, state) {

@@ -130,3 +121,3 @@ if (state) {

} else state = record;
state.type = ASYNC_ITERATOR_PROXY;
state.type = IS_ITERATOR ? WRAP_FOR_VALID_ASYNC_ITERATOR : ASYNC_ITERATOR_HELPER;
state.nextHandler = nextHandler;

@@ -133,0 +124,0 @@ state.counter = 0;

@@ -22,4 +22,4 @@ 'use strict';

// fallback for uncaught frozen keys
var uncaughtFrozenStore = function (store) {
return store.frozen || (store.frozen = new UncaughtFrozenStore());
var uncaughtFrozenStore = function (state) {
return state.frozen || (state.frozen = new UncaughtFrozenStore());
};

@@ -26,0 +26,0 @@

var userAgent = require('../internals/engine-user-agent');
var global = require('../internals/global');
module.exports = /ipad|iphone|ipod/i.test(userAgent) && global.Pebble !== undefined;
module.exports = /ipad|iphone|ipod/i.test(userAgent) && typeof Pebble != 'undefined';
var classof = require('../internals/classof-raw');
var global = require('../internals/global');
module.exports = classof(global.process) == 'process';
module.exports = typeof process != 'undefined' && classof(process) == 'process';

@@ -1,3 +0,1 @@

var getBuiltIn = require('../internals/get-built-in');
module.exports = getBuiltIn('navigator', 'userAgent') || '';
module.exports = typeof navigator != 'undefined' && String(navigator.userAgent) || '';

@@ -73,3 +73,3 @@ 'use strict';

// bind timers to global for call from export context
// bind methods to global for calling from export context
if (options.bind && USE_NATIVE) resultProperty = bind(sourceProperty, global);

@@ -76,0 +76,0 @@ // wrap global constructors for prevent changs in this version

@@ -7,2 +7,3 @@ var aCallable = require('../internals/a-callable');

var $TypeError = TypeError;
var max = Math.max;

@@ -35,3 +36,3 @@ var SetRecord = function (set, size, has, keys) {

obj,
toIntegerOrInfinity(numSize),
max(toIntegerOrInfinity(numSize), 0),
aCallable(obj.has),

@@ -38,0 +39,0 @@ aCallable(obj.keys)

@@ -1,8 +0,6 @@

var global = require('../internals/global');
module.exports = function (a, b) {
var console = global.console;
if (console && console.error) {
try {
// eslint-disable-next-line no-console -- safe
arguments.length == 1 ? console.error(a) : console.error(a, b);
}
} catch (error) { /* empty */ }
};
var classof = require('../internals/classof');
var uncurryThis = require('../internals/function-uncurry-this');
var slice = uncurryThis(''.slice);
module.exports = function (it) {
return slice(classof(it), 0, 3) === 'Big';
var klass = classof(it);
return klass == 'BigInt64Array' || klass == 'BigUint64Array';
};

@@ -13,2 +13,3 @@ 'use strict';

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var ITERATOR_HELPER = 'IteratorHelper';

@@ -18,10 +19,6 @@ var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var createIteratorProxyPrototype = function (IS_ITERATOR) {
var ITERATOR_PROXY = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
var getInternalState = InternalStateModule.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);
var getInternalState = InternalStateModule.getterFor(ITERATOR_PROXY);
var IteratorProxyPrototype = defineBuiltIns(create(IteratorPrototype), {
return defineBuiltIns(create(IteratorPrototype), {
next: function next() {

@@ -50,24 +47,18 @@ var state = getInternalState(this);

if (state.inner) try {
iteratorClose(state.inner.iterator, 'return');
iteratorClose(state.inner.iterator, 'normal');
} catch (error) {
return iteratorClose(iterator, 'throw', error);
}
iteratorClose(iterator, 'return');
iteratorClose(iterator, 'normal');
return createIterResultObject(undefined, true);
}
});
if (!IS_ITERATOR) {
createNonEnumerableProperty(IteratorProxyPrototype, TO_STRING_TAG, 'Iterator Helper');
}
return IteratorProxyPrototype;
};
var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
var IteratorHelperPrototype = createIteratorProxyPrototype(false);
var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
createNonEnumerableProperty(IteratorHelperPrototype, TO_STRING_TAG, 'Iterator Helper');
module.exports = function (nextHandler, IS_ITERATOR) {
var ITERATOR_PROXY = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
var IteratorProxy = function Iterator(record, state) {

@@ -78,3 +69,3 @@ if (state) {

} else state = record;
state.type = ITERATOR_PROXY;
state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
state.nextHandler = nextHandler;

@@ -81,0 +72,0 @@ state.counter = 0;

@@ -5,2 +5,3 @@ var global = require('../internals/global');

var macrotask = require('../internals/task').set;
var Queue = require('../internals/queue');
var IS_IOS = require('../internals/engine-is-ios');

@@ -17,22 +18,18 @@ var IS_IOS_PEBBLE = require('../internals/engine-is-ios-pebble');

var queueMicrotaskDescriptor = getOwnPropertyDescriptor(global, 'queueMicrotask');
var queueMicrotask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;
var microtask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;
var notify, toggle, node, promise, then;
var flush, head, last, notify, toggle, node, promise, then;
// modern engines have queueMicrotask method
if (!microtask) {
var queue = new Queue();
// modern engines have queueMicrotask method
if (!queueMicrotask) {
flush = function () {
var flush = function () {
var parent, fn;
if (IS_NODE && (parent = process.domain)) parent.exit();
while (head) {
fn = head.fn;
head = head.next;
try {
fn();
} catch (error) {
if (head) notify();
else last = undefined;
throw error;
}
} last = undefined;
while (fn = queue.get()) try {
fn();
} catch (error) {
if (queue.head) notify();
throw error;
}
if (parent) parent.enter();

@@ -72,3 +69,3 @@ };

} else {
// strange IE + webpack dev server bug - use .bind(global)
// `webpack` dev server bug on IE global methods - use bind(fn, global)
macrotask = bind(macrotask, global);

@@ -79,11 +76,9 @@ notify = function () {

}
microtask = function (fn) {
if (!queue.head) notify();
queue.add(fn);
};
}
module.exports = queueMicrotask || function (fn) {
var task = { fn: fn, next: undefined };
if (last) last.next = task;
if (!head) {
head = task;
notify();
} last = task;
};
module.exports = microtask;

@@ -9,3 +9,4 @@ var Queue = function () {

var entry = { item: item, next: null };
if (this.head) this.tail.next = entry;
var tail = this.tail;
if (tail) tail.next = entry;
else this.head = entry;

@@ -17,4 +18,4 @@ this.tail = entry;

if (entry) {
this.head = entry.next;
if (this.tail === entry) this.tail = null;
var next = this.head = entry.next;
if (next === null) this.tail = null;
return entry.item;

@@ -21,0 +22,0 @@ }

@@ -8,2 +8,3 @@ 'use strict';

var iterateSimple = require('../internals/iterate-simple');
var iteratorClose = require('../internals/iterator-close');

@@ -15,10 +16,9 @@ // `Set.prototype.isDisjointFrom` method

var otherRec = getSetRecord(other);
return false !== (size(O) <= otherRec.size
? iterateSet(O, function (e) {
if (otherRec.includes(e)) return false;
}, true)
: iterateSimple(otherRec.getIterator(), function (e) {
if (has(O, e)) return false;
})
);
if (size(O) <= otherRec.size) return iterateSet(O, function (e) {
if (otherRec.includes(e)) return false;
}, true) !== false;
var iterator = otherRec.getIterator();
return iterateSimple(iterator, function (e) {
if (has(O, e)) return iteratorClose(iterator, 'normal', false);
}) !== false;
};

@@ -7,2 +7,3 @@ 'use strict';

var iterateSimple = require('../internals/iterate-simple');
var iteratorClose = require('../internals/iterator-close');

@@ -15,5 +16,6 @@ // `Set.prototype.isSupersetOf` method

if (size(O) < otherRec.size) return false;
return iterateSimple(otherRec.getIterator(), function (e) {
if (has(O, e) === false) return false;
var iterator = otherRec.getIterator();
return iterateSimple(iterator, function (e) {
if (!has(O, e)) return iteratorClose(iterator, 'normal', false);
}) !== false;
};

@@ -7,7 +7,7 @@ var IS_PURE = require('../internals/is-pure');

})('versions', []).push({
version: '3.27.1',
version: '3.27.2',
mode: IS_PURE ? 'pure' : 'global',
copyright: '© 2014-2022 Denis Pushkarev (zloirock.ru)',
license: 'https://github.com/zloirock/core-js/blob/v3.27.1/LICENSE',
copyright: '© 2014-2023 Denis Pushkarev (zloirock.ru)',
license: 'https://github.com/zloirock/core-js/blob/v3.27.2/LICENSE',
source: 'https://github.com/zloirock/core-js'
});

@@ -10,5 +10,8 @@ var uncurryThis = require('../internals/function-uncurry-this');

// `String.cooked` method
// https://tc39.es/proposal-string-cooked/
module.exports = function cooked(template /* , ...substitutions */) {
var cookedTemplate = toIndexedObject(template);
var literalSegments = lengthOfArrayLike(cookedTemplate);
if (!literalSegments) return '';
var argumentsLength = arguments.length;

@@ -15,0 +18,0 @@ var elements = [];

@@ -1,2 +0,1 @@

'use strict';
// based on https://github.com/bestiejs/punycode.js/blob/master/punycode.js

@@ -3,0 +2,0 @@ var uncurryThis = require('../internals/function-uncurry-this');

@@ -26,6 +26,6 @@ var global = require('../internals/global');

try {
fails(function () {
// Deno throws a ReferenceError on `location` access without `--location` flag
$location = global.location;
} catch (error) { /* empty */ }
});

@@ -46,7 +46,7 @@ var run = function (id) {

var listener = function (event) {
var eventListener = function (event) {
run(event.data);
};
var post = function (id) {
var globalPostMessageDefer = function (id) {
// old engines have not location.origin

@@ -86,3 +86,3 @@ global.postMessage(String(id), $location.protocol + '//' + $location.host);

port = channel.port2;
channel.port1.onmessage = listener;
channel.port1.onmessage = eventListener;
defer = bind(port.postMessage, port);

@@ -96,6 +96,6 @@ // Browsers with postMessage, skip WebWorkers

$location && $location.protocol !== 'file:' &&
!fails(post)
!fails(globalPostMessageDefer)
) {
defer = post;
global.addEventListener('message', listener, false);
defer = globalPostMessageDefer;
global.addEventListener('message', eventListener, false);
// IE8-

@@ -102,0 +102,0 @@ } else if (ONREADYSTATECHANGE in createElement('script')) {

@@ -8,18 +8,12 @@ var global = require('../internals/global');

var Symbol = global.Symbol;
var WellKnownSymbolsStore = shared('wks');
var Symbol = global.Symbol;
var symbolFor = Symbol && Symbol['for'];
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol : Symbol && Symbol.withoutSetter || uid;
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol['for'] || Symbol : Symbol && Symbol.withoutSetter || uid;
module.exports = function (name) {
if (!hasOwn(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {
var description = 'Symbol.' + name;
if (NATIVE_SYMBOL && hasOwn(Symbol, name)) {
WellKnownSymbolsStore[name] = Symbol[name];
} else if (USE_SYMBOL_AS_UID && symbolFor) {
WellKnownSymbolsStore[name] = symbolFor(description);
} else {
WellKnownSymbolsStore[name] = createWellKnownSymbol(description);
}
if (!hasOwn(WellKnownSymbolsStore, name)) {
WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn(Symbol, name)
? Symbol[name]
: createWellKnownSymbol('Symbol.' + name);
} return WellKnownSymbolsStore[name];
};

@@ -12,4 +12,3 @@ 'use strict';

var installErrorCause = require('../internals/install-error-cause');
var clearErrorStack = require('../internals/error-stack-clear');
var ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable');
var installErrorStack = require('../internals/error-stack-install');
var DESCRIPTORS = require('../internals/descriptors');

@@ -40,3 +39,3 @@ var IS_PURE = require('../internals/is-pure');

if (message !== undefined) createNonEnumerableProperty(result, 'message', message);
if (ERROR_STACK_INSTALLABLE) createNonEnumerableProperty(result, 'stack', clearErrorStack(result.stack, 2));
installErrorStack(result, WrappedError, result.stack, 2);
if (this && isPrototypeOf(OriginalErrorPrototype, this)) inheritIfRequired(result, this, WrappedError);

@@ -43,0 +42,0 @@ if (arguments.length > OPTIONS_POSITION) installErrorCause(result, arguments[OPTIONS_POSITION]);

@@ -10,8 +10,7 @@ 'use strict';

var createPropertyDescriptor = require('../internals/create-property-descriptor');
var clearErrorStack = require('../internals/error-stack-clear');
var installErrorCause = require('../internals/install-error-cause');
var installErrorStack = require('../internals/error-stack-install');
var iterate = require('../internals/iterate');
var normalizeStringArgument = require('../internals/normalize-string-argument');
var wellKnownSymbol = require('../internals/well-known-symbol');
var ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable');

@@ -23,3 +22,2 @@ var TO_STRING_TAG = wellKnownSymbol('toStringTag');

var $AggregateError = function AggregateError(errors, message /* , options */) {
var options = arguments.length > 2 ? arguments[2] : undefined;
var isInstance = isPrototypeOf(AggregateErrorPrototype, this);

@@ -34,4 +32,4 @@ var that;

if (message !== undefined) createNonEnumerableProperty(that, 'message', normalizeStringArgument(message));
if (ERROR_STACK_INSTALLABLE) createNonEnumerableProperty(that, 'stack', clearErrorStack(that.stack, 1));
installErrorCause(that, options);
installErrorStack(that, $AggregateError, that.stack, 1);
if (arguments.length > 2) installErrorCause(that, arguments[2]);
var errorsArray = [];

@@ -38,0 +36,0 @@ iterate(errors, push, { that: errorsArray });

@@ -26,4 +26,2 @@ 'use strict';

var SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('concat');
var isConcatSpreadable = function (O) {

@@ -35,3 +33,3 @@ if (!isObject(O)) return false;

var FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !SPECIES_SUPPORT;
var FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !arrayMethodHasSpeciesSupport('concat');

@@ -38,0 +36,0 @@ // `Array.prototype.concat` method

@@ -11,7 +11,7 @@ 'use strict';

var NEGATIVE_ZERO = !!nativeIndexOf && 1 / nativeIndexOf([1], 1, -0) < 0;
var STRICT_METHOD = arrayMethodIsStrict('indexOf');
var FORCED = NEGATIVE_ZERO || !arrayMethodIsStrict('indexOf');
// `Array.prototype.indexOf` method
// https://tc39.es/ecma262/#sec-array.prototype.indexof
$({ target: 'Array', proto: true, forced: NEGATIVE_ZERO || !STRICT_METHOD }, {
$({ target: 'Array', proto: true, forced: FORCED }, {
indexOf: function indexOf(searchElement /* , fromIndex = 0 */) {

@@ -18,0 +18,0 @@ var fromIndex = arguments.length > 1 ? arguments[1] : undefined;

@@ -11,7 +11,7 @@ 'use strict';

var ES3_STRINGS = IndexedObject != Object;
var STRICT_METHOD = arrayMethodIsStrict('join', ',');
var FORCED = ES3_STRINGS || !arrayMethodIsStrict('join', ',');
// `Array.prototype.join` method
// https://tc39.es/ecma262/#sec-array.prototype.join
$({ target: 'Array', proto: true, forced: ES3_STRINGS || !STRICT_METHOD }, {
$({ target: 'Array', proto: true, forced: FORCED }, {
join: function join(separator) {

@@ -18,0 +18,0 @@ return nativeJoin(toIndexedObject(this), separator === undefined ? ',' : separator);

@@ -15,3 +15,3 @@ 'use strict';

// https://bugs.chromium.org/p/v8/issues/detail?id=12681
var SILENT_ON_NON_WRITABLE_LENGTH = !function () {
var properErrorOnNonWritableLength = function () {
try {

@@ -23,7 +23,9 @@ // eslint-disable-next-line es/no-object-defineproperty -- safe

}
}();
};
var FORCED = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength();
// `Array.prototype.push` method
// https://tc39.es/ecma262/#sec-array.prototype.push
$({ target: 'Array', proto: true, arity: 1, forced: INCORRECT_TO_LENGTH || SILENT_ON_NON_WRITABLE_LENGTH }, {
$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {
// eslint-disable-next-line no-unused-vars -- required for `.length`

@@ -30,0 +32,0 @@ push: function push(item) {

@@ -8,10 +8,10 @@ 'use strict';

var STRICT_METHOD = arrayMethodIsStrict('reduceRight');
// Chrome 80-82 has a critical bug
// https://bugs.chromium.org/p/chromium/issues/detail?id=1049982
var CHROME_BUG = !IS_NODE && CHROME_VERSION > 79 && CHROME_VERSION < 83;
var FORCED = CHROME_BUG || !arrayMethodIsStrict('reduceRight');
// `Array.prototype.reduceRight` method
// https://tc39.es/ecma262/#sec-array.prototype.reduceright
$({ target: 'Array', proto: true, forced: !STRICT_METHOD || CHROME_BUG }, {
$({ target: 'Array', proto: true, forced: FORCED }, {
reduceRight: function reduceRight(callbackfn /* , initialValue */) {

@@ -18,0 +18,0 @@ return $reduceRight(this, callbackfn, arguments.length, arguments.length > 1 ? arguments[1] : undefined);

@@ -8,10 +8,10 @@ 'use strict';

var STRICT_METHOD = arrayMethodIsStrict('reduce');
// Chrome 80-82 has a critical bug
// https://bugs.chromium.org/p/chromium/issues/detail?id=1049982
var CHROME_BUG = !IS_NODE && CHROME_VERSION > 79 && CHROME_VERSION < 83;
var FORCED = CHROME_BUG || !arrayMethodIsStrict('reduce');
// `Array.prototype.reduce` method
// https://tc39.es/ecma262/#sec-array.prototype.reduce
$({ target: 'Array', proto: true, forced: !STRICT_METHOD || CHROME_BUG }, {
$({ target: 'Array', proto: true, forced: FORCED }, {
reduce: function reduce(callbackfn /* , initialValue */) {

@@ -18,0 +18,0 @@ var length = arguments.length;

@@ -13,3 +13,3 @@ 'use strict';

// V8 ~ Chrome < 71 and Safari <= 15.4, FF < 23 throws InternalError
var SILENT_ON_NON_WRITABLE_LENGTH = !function () {
var properErrorOnNonWritableLength = function () {
try {

@@ -21,7 +21,9 @@ // eslint-disable-next-line es/no-object-defineproperty -- safe

}
}();
};
var FORCED = INCORRECT_RESULT || !properErrorOnNonWritableLength();
// `Array.prototype.unshift` method
// https://tc39.es/ecma262/#sec-array.prototype.unshift
$({ target: 'Array', proto: true, arity: 1, forced: INCORRECT_RESULT || SILENT_ON_NON_WRITABLE_LENGTH }, {
$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {
// eslint-disable-next-line no-unused-vars -- required for `.length`

@@ -28,0 +30,0 @@ unshift: function unshift(item) {

@@ -6,2 +6,3 @@ 'use strict';

// IE8- non-standard case
var FORCED = fails(function () {

@@ -8,0 +9,0 @@ return new Date(16e11).getYear() !== 120;

@@ -26,2 +26,3 @@ /* eslint-disable no-unused-vars -- required for functions `.length` */

// https://tc39.es/ecma262/#sec-nativeerror
// https://github.com/tc39/proposal-error-cause

@@ -28,0 +29,0 @@ exportGlobalErrorCauseWrapper('Error', function (init) {

@@ -13,7 +13,9 @@ var $ = require('../internals/export');

var FORCED = !($asinh && 1 / $asinh(0) > 0);
// `Math.asinh` method
// https://tc39.es/ecma262/#sec-math.asinh
// Tor Browser bug: Math.asinh(0) -> -0
$({ target: 'Math', stat: true, forced: !($asinh && 1 / $asinh(0) > 0) }, {
$({ target: 'Math', stat: true, forced: FORCED }, {
asinh: asinh
});

@@ -7,6 +7,8 @@ var $ = require('../internals/export');

var FORCED = !($atanh && 1 / $atanh(-0) < 0);
// `Math.atanh` method
// https://tc39.es/ecma262/#sec-math.atanh
// Tor Browser bug: Math.atanh(-0) -> 0
$({ target: 'Math', stat: true, forced: !($atanh && 1 / $atanh(-0) < 0) }, {
$({ target: 'Math', stat: true, forced: FORCED }, {
atanh: function atanh(x) {

@@ -13,0 +15,0 @@ var n = +x;

@@ -9,5 +9,7 @@ var $ = require('../internals/export');

var FORCED = !$cosh || $cosh(710) === Infinity;
// `Math.cosh` method
// https://tc39.es/ecma262/#sec-math.cosh
$({ target: 'Math', stat: true, forced: !$cosh || $cosh(710) === Infinity }, {
$({ target: 'Math', stat: true, forced: FORCED }, {
cosh: function cosh(x) {

@@ -14,0 +16,0 @@ var t = expm1(abs(x) - 1) + 1;

@@ -10,7 +10,7 @@ var $ = require('../internals/export');

// https://bugs.chromium.org/p/v8/issues/detail?id=9546
var BUGGY = !!$hypot && $hypot(Infinity, NaN) !== Infinity;
var FORCED = !!$hypot && $hypot(Infinity, NaN) !== Infinity;
// `Math.hypot` method
// https://tc39.es/ecma262/#sec-math.hypot
$({ target: 'Math', stat: true, arity: 2, forced: BUGGY }, {
$({ target: 'Math', stat: true, arity: 2, forced: FORCED }, {
// eslint-disable-next-line no-unused-vars -- required for `.length`

@@ -17,0 +17,0 @@ hypot: function hypot(value1, value2) {

@@ -31,16 +31,19 @@ 'use strict';

// IE8-
var THROWS_ON_INFINITY_FRACTION = fails(function () {
nativeToExponential(1, Infinity);
}) && fails(function () {
nativeToExponential(1, -Infinity);
});
var throwsOnInfinityFraction = function () {
return fails(function () {
nativeToExponential(1, Infinity);
}) && fails(function () {
nativeToExponential(1, -Infinity);
});
};
// Safari <11 && FF <50
var PROPER_NON_FINITE_THIS_CHECK = !fails(function () {
nativeToExponential(Infinity, Infinity);
}) && !fails(function () {
nativeToExponential(NaN, Infinity);
});
var properNonFiniteThisCheck = function () {
return !fails(function () {
nativeToExponential(Infinity, Infinity);
nativeToExponential(NaN, Infinity);
});
};
var FORCED = !ROUNDS_PROPERLY || !THROWS_ON_INFINITY_FRACTION || !PROPER_NON_FINITE_THIS_CHECK;
var FORCED = !ROUNDS_PROPERLY || !throwsOnInfinityFraction() || !properNonFiniteThisCheck();

@@ -47,0 +50,0 @@ // `Number.prototype.toExponential` method

@@ -7,4 +7,3 @@ var $ = require('../internals/export');

var FAILS_ON_PRIMITIVES = fails(function () { nativeGetOwnPropertyDescriptor(1); });
var FORCED = !DESCRIPTORS || FAILS_ON_PRIMITIVES;
var FORCED = !DESCRIPTORS || fails(function () { nativeGetOwnPropertyDescriptor(1); });

@@ -11,0 +10,0 @@ // `Object.getOwnPropertyDescriptor` method

@@ -9,7 +9,8 @@ var $ = require('../internals/export');

var $isFrozen = Object.isFrozen;
var FAILS_ON_PRIMITIVES = fails(function () { $isFrozen(1); });
var FORCED = ARRAY_BUFFER_NON_EXTENSIBLE || fails(function () { $isFrozen(1); });
// `Object.isFrozen` method
// https://tc39.es/ecma262/#sec-object.isfrozen
$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES || ARRAY_BUFFER_NON_EXTENSIBLE }, {
$({ target: 'Object', stat: true, forced: FORCED }, {
isFrozen: function isFrozen(it) {

@@ -16,0 +17,0 @@ if (!isObject(it)) return true;

@@ -9,7 +9,8 @@ var $ = require('../internals/export');

var $isSealed = Object.isSealed;
var FAILS_ON_PRIMITIVES = fails(function () { $isSealed(1); });
var FORCED = ARRAY_BUFFER_NON_EXTENSIBLE || fails(function () { $isSealed(1); });
// `Object.isSealed` method
// https://tc39.es/ecma262/#sec-object.issealed
$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES || ARRAY_BUFFER_NON_EXTENSIBLE }, {
$({ target: 'Object', stat: true, forced: FORCED }, {
isSealed: function isSealed(it) {

@@ -16,0 +17,0 @@ if (!isObject(it)) return true;

@@ -8,6 +8,7 @@ 'use strict';

var iterate = require('../internals/iterate');
var PROMISE_STATICS_INCORRECT_ITERATION = require('../internals/promise-statics-incorrect-iteration');
// `Promise.allSettled` method
// https://tc39.es/ecma262/#sec-promise.allsettled
$({ target: 'Promise', stat: true }, {
$({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
allSettled: function allSettled(iterable) {

@@ -14,0 +15,0 @@ var C = this;

@@ -9,2 +9,3 @@ 'use strict';

var iterate = require('../internals/iterate');
var PROMISE_STATICS_INCORRECT_ITERATION = require('../internals/promise-statics-incorrect-iteration');

@@ -15,3 +16,3 @@ var PROMISE_ANY_ERROR = 'No one promise resolved';

// https://tc39.es/ecma262/#sec-promise.any
$({ target: 'Promise', stat: true }, {
$({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
any: function any(iterable) {

@@ -18,0 +19,0 @@ var C = this;

@@ -17,6 +17,7 @@ var $ = require('../internals/export');

var literalSegments = lengthOfArrayLike(rawTemplate);
if (!literalSegments) return '';
var argumentsLength = arguments.length;
var elements = [];
var i = 0;
while (literalSegments > i) {
while (true) {
push(elements, toString(rawTemplate[i++]));

@@ -23,0 +24,0 @@ if (i === literalSegments) return join(elements, '');

@@ -12,3 +12,3 @@ 'use strict';

// eslint-disable-next-line unicorn/prefer-string-slice, es/no-string-prototype-substr -- required for testing
// eslint-disable-next-line unicorn/prefer-string-slice -- required for testing
var FORCED = !''.substr || 'ab'.substr(-1) !== 'b';

@@ -15,0 +15,0 @@

@@ -10,7 +10,6 @@ 'use strict';

var createPropertyDescriptor = require('../internals/create-property-descriptor');
var clearErrorStack = require('../internals/error-stack-clear');
var installErrorCause = require('../internals/install-error-cause');
var installErrorStack = require('../internals/error-stack-install');
var normalizeStringArgument = require('../internals/normalize-string-argument');
var wellKnownSymbol = require('../internals/well-known-symbol');
var ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable');

@@ -21,3 +20,2 @@ var TO_STRING_TAG = wellKnownSymbol('toStringTag');

var $SuppressedError = function SuppressedError(error, suppressed, message /* , options */) {
var options = arguments.length > 3 ? arguments[3] : undefined;
var isInstance = isPrototypeOf(SuppressedErrorPrototype, this);

@@ -32,4 +30,4 @@ var that;

if (message !== undefined) createNonEnumerableProperty(that, 'message', normalizeStringArgument(message));
if (ERROR_STACK_INSTALLABLE) createNonEnumerableProperty(that, 'stack', clearErrorStack(that.stack, 1));
installErrorCause(that, options);
installErrorStack(that, $SuppressedError, that.stack, 1);
if (arguments.length > 3) installErrorCause(that, arguments[3]);
createNonEnumerableProperty(that, 'error', error);

@@ -36,0 +34,0 @@ createNonEnumerableProperty(that, 'suppressed', suppressed);

var $ = require('../internals/export');
var global = require('../internals/global');
var getBuiltIn = require('../internals/get-built-in');
var uncurryThis = require('../internals/function-uncurry-this');
var call = require('../internals/function-call');
var fails = require('../internals/fails');

@@ -36,6 +38,7 @@ var toString = require('../internals/to-string');

// https://html.spec.whatwg.org/multipage/webappapis.html#dom-atob
$({ global: true, enumerable: true, forced: NO_SPACES_IGNORE || NO_ENCODING_CHECK || NO_ARG_RECEIVING_CHECK || WRONG_ARITY }, {
$({ global: true, bind: true, enumerable: true, forced: NO_SPACES_IGNORE || NO_ENCODING_CHECK || NO_ARG_RECEIVING_CHECK || WRONG_ARITY }, {
atob: function atob(data) {
validateArgumentsLength(arguments.length, 1);
if (NO_ARG_RECEIVING_CHECK || WRONG_ARITY) return $atob(data);
// `webpack` dev server bug on IE global methods - use call(fn, global, ...)
if (NO_ARG_RECEIVING_CHECK || WRONG_ARITY) return call($atob, global, data);
var string = replace(toString(data), whitespaces, '');

@@ -42,0 +45,0 @@ var output = '';

var $ = require('../internals/export');
var global = require('../internals/global');
var getBuiltIn = require('../internals/get-built-in');
var uncurryThis = require('../internals/function-uncurry-this');
var call = require('../internals/function-call');
var fails = require('../internals/fails');

@@ -25,6 +27,7 @@ var toString = require('../internals/to-string');

// https://html.spec.whatwg.org/multipage/webappapis.html#dom-btoa
$({ global: true, enumerable: true, forced: NO_ARG_RECEIVING_CHECK || WRONG_ARG_CONVERSION || WRONG_ARITY }, {
$({ global: true, bind: true, enumerable: true, forced: NO_ARG_RECEIVING_CHECK || WRONG_ARG_CONVERSION || WRONG_ARITY }, {
btoa: function btoa(data) {
validateArgumentsLength(arguments.length, 1);
if (NO_ARG_RECEIVING_CHECK || WRONG_ARG_CONVERSION || WRONG_ARITY) return $btoa(toString(data));
// `webpack` dev server bug on IE global methods - use call(fn, global, ...)
if (NO_ARG_RECEIVING_CHECK || WRONG_ARG_CONVERSION || WRONG_ARITY) return call($btoa, global, toString(data));
var string = toString(data);

@@ -31,0 +34,0 @@ var output = '';

@@ -83,4 +83,7 @@ 'use strict';

if (DESCRIPTORS) {
// `DOMException.prototype.code` getter
defineBuiltInAccessor(DOMExceptionPrototype, 'code', getterFor('code'));
// `DOMException.prototype.message` getter
defineBuiltInAccessor(DOMExceptionPrototype, 'message', getterFor('message'));
// `DOMException.prototype.name` getter
defineBuiltInAccessor(DOMExceptionPrototype, 'name', getterFor('name'));

@@ -132,2 +135,3 @@ }

// `DOMException` constants
for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) {

@@ -134,0 +138,0 @@ var constant = DOMExceptionConstants[key];

@@ -6,2 +6,3 @@ var getBuiltIn = require('../internals/get-built-in');

// `DOMException.prototype[@@toStringTag]` property
setToStringTag(getBuiltIn(DOM_EXCEPTION), DOM_EXCEPTION);
{
"name": "core-js-pure",
"version": "3.27.1",
"version": "3.27.2",
"description": "Standard library",

@@ -5,0 +5,0 @@ "keywords": [

var fs = require('fs');
var os = require('os');
var path = require('path');
var env = process.env;
var ADBLOCK = is(env.ADBLOCK);

@@ -7,0 +7,0 @@ var COLOR = is(env.npm_config_color);

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc