Google Analytics
This commit is contained in:
@@ -9,6 +9,15 @@
|
|||||||
<link rel="icon" href="favicon.ico" type="image/x-icon">
|
<link rel="icon" href="favicon.ico" type="image/x-icon">
|
||||||
<link rel="stylesheet" href="passmate.css">
|
<link rel="stylesheet" href="passmate.css">
|
||||||
<script src="passmate.js" async></script>
|
<script src="passmate.js" async></script>
|
||||||
|
|
||||||
|
<!-- Global site tag (gtag.js) - Google Analytics -->
|
||||||
|
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-130661405-1"></script>
|
||||||
|
<script>
|
||||||
|
window.dataLayer = window.dataLayer || [];
|
||||||
|
function gtag(){dataLayer.push(arguments);}
|
||||||
|
gtag('js', new Date());
|
||||||
|
gtag('config', 'UA-130661405-1');
|
||||||
|
</script>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
@@ -109,6 +109,8 @@ class PassMate {
|
|||||||
let print = this.addElement('button', printStep, 'Click here to print the book!');
|
let print = this.addElement('button', printStep, 'Click here to print the book!');
|
||||||
print.style.cursor = 'pointer';
|
print.style.cursor = 'pointer';
|
||||||
printStep.addEventListener('click', () => {
|
printStep.addEventListener('click', () => {
|
||||||
|
let ga = window.ga || () => {};
|
||||||
|
ga('send', 'event', 'Overview', 'print');
|
||||||
window.print();
|
window.print();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user