Created
August 16, 2019 09:51
-
-
Save antlis/08ad32130e9133343619086fc2accb24 to your computer and use it in GitHub Desktop.
GTAG Script 2019, pug mixin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mixin ga(id) | |
script(async='', src='https://www.googletagmanager.com/gtag/js?id='+id) | |
script. | |
window.dataLayer = window.dataLayer || []; | |
function gtag(){dataLayer.push(arguments);} | |
gtag('js', new Date()); | |
gtag('config', '!{id}') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment