We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 893db5d commit 85d168fCopy full SHA for 85d168f
ReflectLite.ts
@@ -571,16 +571,8 @@ namespace Reflect {
571
};
572
}
573
574
- function functionThis() {
575
- try { return Function("return this;")(); } catch (_) { }
576
- }
577
-
578
- function indirectEvalThis() {
579
- try { return (void 0, eval)("(function() { return this; })()"); } catch (_) { }
580
581
582
- function sloppyModeThis() {
583
- return functionThis() || indirectEvalThis();
+ function sloppyModeThis(): never {
+ throw new ReferenceError("globalThis could not be found. Please polyfill globalThis before loading this module.");
584
585
})
586
(function (exporter, root) {
0 commit comments