External JavaScript

  • This is generally a good thing in terms of organizing your code and making it reusable across multiple HTML files. Plus, the HTML is easier to read without huge chunks of script dumped in it.
  • Note the defer option? I does the same thing as the “DOMContentLoaded” 
  • Order matters when loading scripts. Show examples
Scroll to Top