Skip to content

Commit

Permalink
added google tag manager
Browse files Browse the repository at this point in the history
  • Loading branch information
Kashaan-M committed Jan 29, 2024
1 parent 638b143 commit 8dfbae4
Showing 1 changed file with 16 additions and 23 deletions.
39 changes: 16 additions & 23 deletions _includes/layouts/base.html
Original file line number Diff line number Diff line change
@@ -1,29 +1,31 @@
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Google tag (gtag.js) -->
<script
async
src="https://www.googletagmanager.com/gtag/js?id=G-T5Z2TQCWBM"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());

gtag('config', 'G-T5Z2TQCWBM');
</script>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="googlebot" content="index,follow" />
<meta name="title" content="{{title}}" />
<meta name="description" content="{{description}}" />
<meta property="og:title" content="{{title}}" />
<meta property="og:description" content="{{description}}" />
<meta property="og:url" content="{{ page.url }}" />
<meta property="og:type" content="website" />
<meta name="description" content="{{description}}" />
<link rel="stylesheet" href="{{'/public/css/styles.css' | url }}" />
<script src="{{'/public/js/index.js'| url }}" defer></script>
<!-- Google Tag Manager -->
<script>
(function (w, d, s, l, i) {
w[l] = w[l] || [];
w[l].push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' });
var f = d.getElementsByTagName(s)[0],
j = d.createElement(s),
dl = l != 'dataLayer' ? '&l=' + l : '';
j.async = true;
j.src = 'https://www.googletagmanager.com/gtm.js?id=' + i + dl;
f.parentNode.insertBefore(j, f);
})(window, document, 'script', 'dataLayer', 'GTM-PN545LG');
</script>
<!-- End Google Tag Manager -->
<title>{{title}}</title>
</head>
<body class="light">
Expand All @@ -50,14 +52,5 @@ <h3>
>LinkedIn</a
>
</footer>
<!-- Google Tag Manager (noscript) -->
<noscript
><iframe
src="https://www.googletagmanager.com/ns.html?id=GTM-PN545LG"
height="0"
width="0"
style="display: none; visibility: hidden"></iframe
></noscript>
<!-- End Google Tag Manager (noscript) -->
</body>
</html>

0 comments on commit 8dfbae4

Please sign in to comment.