|
|
|
@ -17,8 +17,11 @@ if (domains[window.location.hostname]) { |
|
|
|
|
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */ |
|
|
|
|
_paq.push(["setExcludedQueryParams", ["code","gist"]]); |
|
|
|
|
_paq.push(["setExcludedReferrers", ["etherscan.io"]]); |
|
|
|
|
_paq.push(['disableCookies']); |
|
|
|
|
_paq.push(['enableJSErrorTracking']); |
|
|
|
|
// require user tracking consent before processing data
|
|
|
|
|
_paq.push(['requireConsent']); |
|
|
|
|
// OR require user cookie consent before storing any cookies
|
|
|
|
|
_paq.push(['requireCookieConsent']); |
|
|
|
|
_paq.push(['trackPageView']); |
|
|
|
|
_paq.push(['enableLinkTracking']); |
|
|
|
|
_paq.push(['enableHeartBeatTimer']); |
|
|
|
@ -38,17 +41,17 @@ if (domains[window.location.hostname]) { |
|
|
|
|
function isElectron() { |
|
|
|
|
// Renderer process
|
|
|
|
|
if (typeof window !== 'undefined' && typeof window.process === 'object' && window.process.type === 'renderer') { |
|
|
|
|
return true |
|
|
|
|
return true |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Main process
|
|
|
|
|
if (typeof process !== 'undefined' && typeof process.versions === 'object' && !!process.versions.electron) { |
|
|
|
|
return true |
|
|
|
|
return true |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Detect the user agent when the `nodeIntegration` option is set to false
|
|
|
|
|
if (typeof navigator === 'object' && typeof navigator.userAgent === 'string' && navigator.userAgent.indexOf('Electron') >= 0) { |
|
|
|
|
return true |
|
|
|
|
return true |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return false |
|
|
|
|