env.js 383 B

123456789101112
  1. export function getDevtoolsGlobalHook() {
  2. return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__;
  3. }
  4. export function getTarget() {
  5. // @ts-ignore
  6. return (typeof navigator !== 'undefined' && typeof window !== 'undefined')
  7. ? window
  8. : typeof global !== 'undefined'
  9. ? global
  10. : {};
  11. }
  12. export const isProxyAvailable = typeof Proxy === 'function';