2022-08-26 10:39:05 -04:00
|
|
|
exports.globalThis = globalThis;
|
|
|
|
exports.global = global;
|
2022-10-21 11:20:18 -04:00
|
|
|
exports.process = process;
|
2023-02-08 19:11:12 -05:00
|
|
|
|
2023-07-19 04:30:04 -04:00
|
|
|
exports.deleteSetTimeout = function () {
|
|
|
|
delete globalThis.setTimeout;
|
2023-02-08 19:11:12 -05:00
|
|
|
};
|
2023-07-19 04:30:04 -04:00
|
|
|
|
|
|
|
exports.getSetTimeout = function () {
|
|
|
|
return globalThis.setTimeout;
|
|
|
|
};
|
|
|
|
|
|
|
|
exports.checkWindowGlobal = function () {
|
|
|
|
console.log("window" in globalThis);
|
|
|
|
console.log(Object.getOwnPropertyDescriptor(globalThis, "window") !== undefined);
|
|
|
|
}
|
|
|
|
|
2024-07-18 23:37:08 -04:00
|
|
|
exports.checkSelfGlobal = function () {
|
|
|
|
console.log("self" in globalThis);
|
|
|
|
console.log(Object.getOwnPropertyDescriptor(globalThis, "self") !== undefined);
|
|
|
|
}
|
|
|
|
|
2023-07-19 04:30:04 -04:00
|
|
|
exports.getFoo = function () {
|
|
|
|
return globalThis.foo;
|
2024-07-18 23:37:08 -04:00
|
|
|
}
|