1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-16 06:44:50 +00:00
This commit is contained in:
jeremy@jermolene.com 2023-06-19 11:55:54 +01:00
parent f195bfa9f2
commit c0720d8fae

View File

@ -27,7 +27,7 @@ exports.startup = function() {
hasInitialised = true; hasInitialised = true;
var gaMeasurementID = $tw.wiki.getTiddlerText("$:/GoogleAnalyticsMeasurementID","").replace(/\n/g,""); var gaMeasurementID = $tw.wiki.getTiddlerText("$:/GoogleAnalyticsMeasurementID","").replace(/\n/g,"");
var url ="https://www.googletagmanager.com/gtag/js?id=" + gaMeasurementID; var url ="https://www.googletagmanager.com/gtag/js?id=" + gaMeasurementID;
window.dataLayer = this.window.dataLayer || []; window.dataLayer = window.dataLayer || [];
window.gtag = function() { window.dataLayer?.push(arguments); }; window.gtag = function() { window.dataLayer?.push(arguments); };
window.gtag("js",new Date()); window.gtag("js",new Date());
window.gtag("config",gaMeasurementID); window.gtag("config",gaMeasurementID);