Skip to content

Instantly share code, notes, and snippets.

@codearachnid
Created November 2, 2022 15:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save codearachnid/952b410fc927a481e2a2e3352bd95995 to your computer and use it in GitHub Desktop.
Save codearachnid/952b410fc927a481e2a2e3352bd95995 to your computer and use it in GitHub Desktop.
Make sure jquery can run inline before lib is loaded in footer of the page
<script>
window.addEventListener("load", function () {
$(function () {
$("body").append("<p>jQuery is available now!</p>");
// Run my big jQuery function
});
}, false);
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment