Skip to content

Commit

Permalink
Change analytics script from Panelbear to Cronitor (#1561)
Browse files Browse the repository at this point in the history
Panelbear is now Cronitor RUM, the old script does not work.
  • Loading branch information
yahaha-233 authored Jul 15, 2023
1 parent bbbb139 commit bdf7bbc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ contact_note: >
# -----------------------------------------------------------------------------

google_analytics: # your Google Analytics measurement ID (format: G-XXXXXXXXXX)
panelbear_analytics: # panelbear analytics site ID (format: XXXXXXXXX)
cronitor_analytics: # cronitor RUM analytics site ID (format: XXXXXXXXX)

google_site_verification: # your google-site-verification ID (Google Search Console)
bing_site_verification: # out your bing-site-verification ID (Bing Webmaster)
Expand Down Expand Up @@ -356,7 +356,7 @@ jekyll-diagrams:
# -----------------------------------------------------------------------------

enable_google_analytics: false # enables google analytics
enable_panelbear_analytics: false # enables panelbear analytics
enable_cronitor_analytics: false # enables cronitor RUM analytics
enable_google_verification: false # enables google site verification
enable_bing_verification: false # enables bing site verification
enable_masonry: true # enables automatic project cards arrangement
Expand Down
10 changes: 5 additions & 5 deletions _includes/scripts/analytics.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
gtag('config', '{{ site.google_analytics }}');
</script>
{%- 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>
{%- if site.enable_cronitor_analytics -%}
<!-- Cronitor RUM -->
<script async src="https://rum.cronitor.io/script.js"></script>
<script>
window.panelbear = window.panelbear || function() { (window.panelbear.q = window.panelbear.q || []).push(arguments); };
panelbear('config', { site: '{{site.panelbear_analytics}}' });
window.cronitor = window.cronitor || function() { (window.cronitor.q = window.cronitor.q || []).push(arguments); };
cronitor('config', { clientKey: '{{site.cronitor_analytics}}' });
</script>
{%- endif -%}

0 comments on commit bdf7bbc

Please sign in to comment.