diff --git a/index.html b/index.html index 9da80bd..4450921 100644 --- a/index.html +++ b/index.html @@ -1,6 +1,14 @@ + + @@ -48,13 +56,6 @@
- + diff --git a/src/App.vue b/src/App.vue index a47519c..6236fe3 100644 --- a/src/App.vue +++ b/src/App.vue @@ -285,13 +285,12 @@ function toRGBA(c) { } function recordOpenClick(link) { - if (typeof ga === 'undefined') return; + if (typeof gtag === 'undefined') return; - ga('send', 'event', { - eventCategory: 'Outbound Link', - eventAction: 'click', - eventLabel: link - }); + gtag('event', 'click', { + 'event_category': 'Outbound Link', + 'event_label': link + }); } diff --git a/src/main.js b/src/main.js index 8450317..e5349d1 100644 --- a/src/main.js +++ b/src/main.js @@ -22,12 +22,12 @@ if (isWebGLEnabled(document.querySelector('#canvas'))) { } function logError(e) { - if (typeof ga !== 'function') return; + if (typeof gtag !== 'function') return; const exDescription = e ? `${e.message} in ${e.filename}:${e.lineno}` : 'Unknown exception'; - ga('send', 'exception', { - exDescription, - exFatal: false + gtag('send', 'exception', { + description: exDescription, + fatal: false }); } \ No newline at end of file