Skip to content

Commit

Permalink
Adds support for GA4 Google Analytics (alshedivat#727)
Browse files Browse the repository at this point in the history
* Update `analytics.html`

* Update `config.yml`

* Update

* Update
  • Loading branch information
rohandebsarkar authored and zkotti committed Dec 10, 2022
1 parent 6347ab6 commit 4572810
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions _includes/scripts/analytics.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
<script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google_analytics }}"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() { dataLayer.push(arguments); }
function gtag(){ window.dataLayer.push(arguments); }
gtag('js', new Date());
gtag('config', '{{ site.google_analytics }}');
</script>
{%- endif -%}
{%- if site.enable_panelbear_analytics -%}
{%- endif -%}
{%- if site.enable_panelbear_analytics -%}
<!-- Panelbear Analytics - We respect your privacy -->
<script async src="https://cdn.panelbear.com/analytics.js?site={{site.panelbear_analytics}}"></script>
<script>
Expand Down

0 comments on commit 4572810

Please sign in to comment.