jQuery being loaded into gtm.js from Google Tag Manager

半世苍凉 提交于 2019-12-05 02:11:30

问题


I've been having an issue where jQuery v1.9.1 is being included into the top of the gtm.js file. It causes a few issues and can blow away jQuery plugins that are already loaded on jQuery.fn. Regression testing is also a concern. I checked and I don't appear to have any custom tags in the Google Tag Manager that loads jQuery.

Ultimately I want to have control over the host domain and version of jQuery loaded. Is there a configuration setting in the GTM interface or some other way that I can disable the inclusion of jQuery?


回答1:


I'm pretty sure that the jQuery code that is included in gtm.js is customized and not globally available.

I did a quick test, and neither jQuery nor $ are defined when I just insert the GTM snippet into a page.

(window.$ actually is defined, but that's a Chrome thing: Commandline API Reference)



来源:https://stackoverflow.com/questions/22207431/jquery-being-loaded-into-gtm-js-from-google-tag-manager

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!