Skip to content

Commit

Permalink
chore: add google analytics for user metrics
Browse files Browse the repository at this point in the history
  • Loading branch information
saladgg committed Sep 12, 2022
1 parent ed50a71 commit 6b894b6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
9 changes: 3 additions & 6 deletions assets/static/js/project.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,11 @@ function switchDashboards(event) {


(function($) {
/* Google Analytics */
/* Google Analytics */
window.dataLayer = window.dataLayer || [];

function gtag() {
dataLayer.push(arguments);
}
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-S5JLWM36RQ');
gtag('config', 'G-6XRLBC4TMR');

// Auto-collapse open menus in responsive mode
$(".navbar-collapse a").click(function() {
Expand Down
5 changes: 3 additions & 2 deletions assets/templates/atoms/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,10 @@
<script defer src="{% static 'js/project.min.js' %}"></script>
{% endcompress %}

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-S5JLWM36RQ"></script>
<script src="https://kit.fontawesome.com/e1c9d8c99d.js" crossorigin="anonymous"></script>

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-6XRLBC4TMR"></script>
{% endblock javascript %}

</head>

0 comments on commit 6b894b6

Please sign in to comment.