add google analytics setting

This commit is contained in:
liangping 2024-03-24 12:11:43 +08:00
parent cf30712e0e
commit 86a5e9c0da

View File

@ -28,7 +28,14 @@
window.dataLayer = window.dataLayer || []; window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);} function gtag(){dataLayer.push(arguments);}
gtag('js', new Date()); gtag('js', new Date());
// Set default consent to 'denied' as a placeholder
// Determine actual values based on your own requirements
gtag('consent', 'default', {
'ad_storage': 'denied',
'ad_user_data': 'denied',
'ad_personalization': 'denied',
'analytics_storage': 'denied'
});
gtag('config', 'G-SSBKVF3GMX'); gtag('config', 'G-SSBKVF3GMX');
</script> </script>
<script type="module" src="https://cdn.jsdelivr.net/npm/ping-widget@latest/dist/ping-widget.min.js"></script> <script type="module" src="https://cdn.jsdelivr.net/npm/ping-widget@latest/dist/ping-widget.min.js"></script>