diff --git a/lms/templates/partials/analytics.html b/lms/templates/partials/analytics.html index 10d97314..23ca883e 100644 --- a/lms/templates/partials/analytics.html +++ b/lms/templates/partials/analytics.html @@ -60,12 +60,15 @@ }]; % endif + ## Add a timeout delay to GTM initialization to avoid breaking video module loading from YouTube + ## with Google Analytics v<4 with Measure Videos turneed on + ## see: https://discuss.openedx.org/t/first-video-on-lesson-dont-work/3836/3 - + };setTimeout(loadGTM.bind(null, window,document,'script','dataLayer','${customer_gtm_id | n, js_escaped_string}'), 1000); % endif