Closed chadwatson closed 9 years ago
We need code here — please post the contests of jquery.throttleDebounce.js
I think your problem is that browserify-shim does not transform whole sources, only local to your project. By default, browserify does not "transform" every modules required. For enable global transforming, use global
option. I found solution into issue: https://github.com/thlorenz/browserify-shim/issues/143
So when you are adding browserify-shim
:
var b = browserify(opts);
b.transform(require('browserify-shim'), { global: true });
Ah yes, didn't catch the external script mention. If this isn't the case please say so and I can reopen.
Thanks for the replies!
I'm getting jQuery from the Google CDN.
Then using a shim file, and linking to it in my
package.json
. package.jsonshim.js
Using my custom Gulp script I receive the following error:
I can successfully use
require('jquery')
in all of my modules.I can't seem to find any documentation on how to shim global modules from an external script and then use them as a dependency for a shimmed module in browserify-shim.