feat(internal): Support globalThis in modern environments (#4628)

pull/7738/head
Игорь Фролов 6 years ago committed by GitHub
parent e593bb6d69
commit 255a18f654

@ -1,3 +1,7 @@
declare const global: any;
export const globals = (typeof window !== 'undefined' ? window : global) as unknown as typeof globalThis;
export const globals = (typeof window !== 'undefined'
? window
: typeof globalThis !== 'undefined'
? globalThis
: global) as unknown as typeof globalThis;

Loading…
Cancel
Save