I have some jQuery which will be put on multiple different HTML pages which I have no clue whether they will have the jQuery Library attached or not. I would like to make it so that it does not load the library if it does already exist on the page so that it can be faster, but I can’t figure out if there is a way to check for whether the library already is attached to the page.
Is there a way?
From HTML5 Boilerplate:
Loads a local jQuery file if it hasn’t already been loaded.