Sha256: 1d08e9d93eca82edeaf7ad9881317b880a0bd103a89c9ac6cdb6b8da4f54647b
Contents?: true
Size: 722 Bytes
Versions: 27
Compression:
Stored size: 722 Bytes
Contents
'use strict'; var define = require('define-properties'); var getPolyfill = require('./polyfill'); module.exports = function shimGlobal() { var polyfill = getPolyfill(); if (define.supportsDescriptors) { var descriptor = Object.getOwnPropertyDescriptor(polyfill, 'globalThis'); if (!descriptor || (descriptor.configurable && (descriptor.enumerable || !descriptor.writable || globalThis !== polyfill))) { // eslint-disable-line max-len Object.defineProperty(polyfill, 'globalThis', { configurable: true, enumerable: false, value: polyfill, writable: true }); } } else if (typeof globalThis !== 'object' || globalThis !== polyfill) { polyfill.globalThis = polyfill; } return polyfill; };
Version data entries
27 entries across 27 versions & 2 rubygems