es-aggregate-error
Version:
ES Proposal spec-compliant shim for AggregateError
20 lines (17 loc) • 417 B
JavaScript
;
var define = require('define-properties');
var globalThis = require('globalthis')();
var getPolyfill = require('./polyfill');
module.exports = function shimAggregateError() {
var polyfill = getPolyfill();
define(
globalThis,
{ AggregateError: polyfill },
{
AggregateError: function testAggregateError() {
return globalThis.AggregateError !== polyfill;
}
}
);
return polyfill;
};