Skip to content

Commit 7a4b465

Browse files
author
Ari
committed
Add hotjar
1 parent 5f14a68 commit 7a4b465

File tree

3 files changed

+20
-4
lines changed

3 files changed

+20
-4
lines changed

package-lock.json

Lines changed: 8 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
"core-js": "^3.6.1",
3333
"vue": "^2.6.10",
3434
"vue-analytics": "^5.22.1",
35+
"vue-hotjar": "^1.1.2",
3536
"vue-i18n": "^8.15.3",
3637
"vuex": "^3.1.2"
3738
},

src/main.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
import Vue from 'vue'
22
import Buefy from 'buefy'
33
import i18n from './i18n'
4-
import VueAnalytics from 'vue-analytics'
54
import App from './App.vue'
65
import store from './store'
76
import './styles/vocab.scss'
87

8+
// Analytics
99
import * as Sentry from '@sentry/browser'
1010
import * as Integrations from '@sentry/integrations'
11+
import Hotjar from 'vue-hotjar'
12+
import VueAnalytics from 'vue-analytics'
1113

1214
import { library } from '@fortawesome/fontawesome-svg-core'
1315
import { faCopy } from '@fortawesome/free-solid-svg-icons/faCopy'
@@ -51,6 +53,14 @@ Sentry.init({
5153
]
5254
})
5355

56+
// Production only since we only have a prod id
57+
if (process.env.NODE_ENV === 'production') {
58+
Vue.use(Hotjar, {
59+
id: '1803702',
60+
isProduction: true
61+
})
62+
}
63+
5464
new Vue({
5565
store,
5666
i18n,

0 commit comments

Comments
 (0)