UNPKG
global
Version:
latest (4.4.0)
4.4.0
4.3.2
4.3.1
4.3.0
4.2.1
4.2.0
4.1.0
4.0.1
4.0.0
3.0.2
3.0.1
3.0.0
2.0.7
2.0.6
2.0.5
2.0.4
2.0.3
2.0.2
2.0.1
1.0.0
0.1.5
Require global variables
github.com/Raynos/global
Raynos/global
global
/
window.js
14 lines
(11 loc)
•
232 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
var
win;
if
(
typeof
window
!==
"undefined"
) { win =
window
; }
else
if
(
typeof
global
!==
"undefined"
) { win =
global
; }
else
if
(
typeof
self !==
"undefined"
){ win = self; }
else
{ win = {}; }
module
.
exports
= win;