However module and module.exports both end up being defined and jQuery is not attached to window.
I would like it attached to window because bootstrap expects it to be on window specifically. I don't want to add a <script> for jQuery. Please let me know what I'm doing wrong. Thanks in advance.
I'm hoping for browserified jQuery to be attached to the window, but I don't believe it is. Per the README:
If I'm reading this correctly then
module
should be undefined when the browserify-shim transform is run when jQuery executes this (https://github.com/jquery/jquery/blob/99e8ff1baa7ae341e94bb89c3e84570c7c3ad9ea/src/intro.js#L17):if ( typeof module === "object" && typeof module.exports === "object" ) {
which should result in window.jQuery and window.$ being defined here https://github.com/jquery/jquery/blob/99e8ff1baa7ae341e94bb89c3e84570c7c3ad9ea/src/exports/global.js#L24-L26:
if ( !noGlobal ) { window.jQuery = window.$ = jQuery; }
However
module
andmodule.exports
both end up being defined and jQuery is not attached to window.I would like it attached to window because bootstrap expects it to be on window specifically. I don't want to add a
<script>
for jQuery. Please let me know what I'm doing wrong. Thanks in advance.