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 734bd8e commit abd2fc3Copy full SHA for abd2fc3
src/builtIns/index.js
@@ -1,7 +1,7 @@
1
import collectionHandlers from './collections'
2
3
// eslint-disable-next-line
4
-const globalObj = Function("return this")();
+const globalObj = typeof window === 'object' ? window : Function('return this')();
5
6
// built-in object can not be wrapped by Proxies
7
// their methods expect the object instance as the 'this' instead of the Proxy wrapper
0 commit comments