> Changing a third-party script is something to avoid if possible! There are
> other ways to define a bundle's references.
> Option 1) If using a bundle.txt file, try adding a [references] section:
> third-party-widget.js
> some-plugin.js
> [references]
> ~/jquery
> This assumes that "jquery" is an alias for the CDN URL. i.e.
> bundles.AddUrlWithAlias("http://cdn.com/jquery.js", "jquery");
> (You can just put the URL into the bundle.txt, but that'll make updating
> versions more work later.)
> ---
> Option 2) Call Bundle.AddReference
> In CassetteConfiguration, try this:
> bundles.Add<ScriptBundle>("path", b => b.AddReference("jquery"));
> Or after the Add* calls, you can get to the bundle by its path:
> bundles["path"].AddReference("jquery");
> ---
> If you do own the script file, then reference either the jquery CDN URL, or
> the alias:
> /// <reference path="~/jquery"/>
> I hope that helps. Please let me know if you have more questions.
> Thanks,
> Andrew
> On 29 December 2011 21:36, John Welborn <jwwel...@gmail.com> wrote:
> > How do I define a reference to an external script?
> > For example, if I'm using jquery as an external reference on a cdn,
> > how do I reference that script for a plugin?
> > Sort of related to this and a previous question... do I need to edit
> > every plugin I download to add a reference to jquery? This seems
> > wrong.