File tree Expand file tree Collapse file tree 3 files changed +12
-10
lines changed
Expand file tree Collapse file tree 3 files changed +12
-10
lines changed Original file line number Diff line number Diff line change @@ -5,16 +5,16 @@ import { config } from '@/config'
55const Analytics : React . FC = ( ) => {
66 return (
77 < >
8+ { /* Privacy-friendly analytics by Plausible */ }
89 < Script
910 async
10- src = { `https://www.googletagmanager.com/gtag/js?id= ${ config . gaTrackingId } ` }
11+ src = { `https://plausible.io/js/ ${ config . plausibleTrackingId } .js ` }
1112 > </ Script >
12- < Script id = "ga-script" >
13- { `window.dataLayer = window.dataLayer || [];
14- function gtag(){dataLayer.push(arguments);}
15- gtag('js', new Date());
16-
17- gtag('config', '${ config . gaTrackingId } ');` }
13+ < Script id = "plausible-scrip" >
14+ { `
15+ window.plausible=window.plausible||function(){(plausible.q=plausible.q||[]).push(arguments)},plausible.init=plausible.init||function(i){plausible.o=i||{}};
16+ plausible.init()
17+ ` }
1818 </ Script >
1919 </ >
2020 )
Original file line number Diff line number Diff line change @@ -93,7 +93,7 @@ export const CookieBanner = ({ children }: PropsWithChildren) => {
9393 } }
9494 >
9595 We use cookies to improve your experience and analyze traffic with
96- Google Analytics. By clicking "Accept" you consent to our
96+ Plausible Analytics. By clicking "Accept" you consent to our
9797 use of cookies.
9898 </ CookieConsent >
9999 ) }
Original file line number Diff line number Diff line change @@ -25,7 +25,8 @@ const localConfig = {
2525 glifNodeUrl :
2626 process . env . NEXT_PUBLIC_GLIF_URL ?? 'https://api.node.glif.io/rpc/v1' ,
2727 isTestnet : process . env . NEXT_PUBLIC_IS_TESTNET ?? 'true' ,
28- gaTrackingId : process . env . NEXT_PUBLIC_GOOGLE_ANALYTICS_TRACKING_ID ?? '' ,
28+ plausibleTrackingId :
29+ process . env . NEXT_PUBLIC_PLAUSIBLE_ANALYTICS_TRACKING_ID ?? '' ,
2930 filfoxUrl :
3031 process . env . NEXT_PUBLIC_FILFOX_URL ?? 'https://calibration.filfox.info/en' ,
3132}
@@ -54,7 +55,8 @@ const prodConfig = {
5455 dmobApiKey : process . env . NEXT_PUBLIC_DMOB_API_KEY ?? '' ,
5556 glifNodeUrl : process . env . NEXT_PUBLIC_GLIF_URL ?? '' ,
5657 isTestnet : process . env . NEXT_PUBLIC_IS_TESTNET ?? 'false' ,
57- gaTrackingId : process . env . NEXT_PUBLIC_GOOGLE_ANALYTICS_TRACKING_ID ?? '' ,
58+ plausibleTrackingId :
59+ process . env . NEXT_PUBLIC_PLAUSIBLE_ANALYTICS_TRACKING_ID ?? '' ,
5860 filfoxUrl : process . env . NEXT_PUBLIC_FILFOX_URL ?? 'https://filfox.info/en' ,
5961}
6062
You can’t perform that action at this time.
0 commit comments