reuixiy / hugo-theme-meme

😝 You can’t spell awesome without MemE!
https://io-oi.me/hugo-theme-meme
MIT License
1.01k stars 279 forks source link

Replace Google Universal Analytics with Google Analytics 4 #383

Open fjchen7 opened 2 years ago

fjchen7 commented 2 years ago

Meme needs trackingID to track traffic in Google Analytics. Only Universal Analytics has tracingID (see here), and this product is going to stop collecting data starting July 1, 2023.

image

It is better to use Google Analytics 4 (which uses measure ID) for traffic tracking instead.

fjchen7 commented 2 years ago

PS: umami is another decent product for website analytics especially for individual site like personal blog.

he-sb commented 11 months ago

@jimzk Hi did you figured out how to enable Google Analytics 4 which use Google tag ID (G-xxxxxx) ?

he-sb commented 11 months ago

@jimzk Hi did you figured out how to enable Google Analytics 4 which use Google tag ID (G-xxxxxx) ?

I figured it out, simply config these two parameters would work:

trackingCodeType = "gtag"
trackingID = "G-xxxxxx"