Skip to content

Commit fccb3c6

Browse files
author
SPRINX0\prochazka
committed
2 parents f060d82 + 71b552c commit fccb3c6

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

assets/js/app.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,8 @@ function sendDownloadEventToGoatCounter(event) {
8080
return;
8181
}
8282

83+
fathom.trackEvent('download-community');
84+
8385
window.goatcounter.count({
8486
path: event,
8587
title: "Download: " + event,

layouts/partials/head/analytics.html

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,26 @@
66
gtag('js', new Date());
77

88
gtag('config', 'G-RXLRS09RMZ');
9+
</script>
10+
11+
<script src="https://cdn.usefathom.com/script.js" data-site="HBACGPGP" defer></script>
12+
13+
<script>
14+
window.addEventListener('load', (event) => {
15+
document.querySelectorAll('a').forEach(item => {
16+
let url = item.getAttribute('href');
17+
18+
if (url && url.startsWith('https://dbgate.io')) {
19+
item.addEventListener('click', event => {
20+
fathom.trackEvent('moveto-premium');
21+
});
22+
}
23+
24+
if (url && url.startsWith('https://demo.dbgate.org')) {
25+
item.addEventListener('click', event => {
26+
fathom.trackEvent('open-demo');
27+
});
28+
}
29+
});
30+
});
931
</script>

0 commit comments

Comments
 (0)