🔰browser-specific features

JSmoduleES module ⟩ browser-specific

  • are always deferred❗️( 👉🏻 See: tab 1️⃣ )

  • doesn’t block HTML processing, they load in parallel with other resources.

  • wait until the HTML document is fully ready, and then run.

  • always “see” the fully loaded HTML-page (⭐️ including HTML elements below them❗️)

  • relative order of scripts is maintained: scripts that go first in the document, execute first.

When using modules, HTML page shows up as it loads, and modules run after that, so the user may see the page before JS code is ready❗️

Last updated