diff options
Diffstat (limited to 'src/components')
| -rw-r--r-- | src/components/Analytics.astro | 38 |
1 files changed, 6 insertions, 32 deletions
diff --git a/src/components/Analytics.astro b/src/components/Analytics.astro index 0352bea..cfe47b0 100644 --- a/src/components/Analytics.astro +++ b/src/components/Analytics.astro @@ -1,33 +1,7 @@ ---- -import { analytics } from "../config/analytics"; - -const GOOGLE_ANALYTICS_ID = analytics.googleAnalyticsId; -const FATHOM_ANALYTICS_ID = analytics.fathomAnalyticsId; ---- - -{ - GOOGLE_ANALYTICS_ID && ( - <script - async - src={`https://www.googletagmanager.com/gtag/js?id=${GOOGLE_ANALYTICS_ID}`} - /> - <script define:vars={{ GOOGLE_ANALYTICS_ID }} is:inline> - window.dataLayer = window.dataLayer || []; - function gtag() { - dataLayer.push(arguments); - } - gtag("js", new Date()); - gtag("config", GOOGLE_ANALYTICS_ID); - </script> - ) -} -{ - FATHOM_ANALYTICS_ID && ( - <script - src="https://cdn.usefathom.com/script.js" - data-site={FATHOM_ANALYTICS_ID} - defer - /> - ) -} +<!-- Privacy-friendly analytics by Plausible --> +<script async src="https://track.magicmonad.com/js/pa-DV9or-AK9tJTmrfO0pE9b.js"></script> +<script is:inline> + window.plausible=window.plausible||function(){(plausible.q=plausible.q||[]).push(arguments)},plausible.init=plausible.init||function(i){plausible.o=i||{}}; + plausible.init() +</script> |
