<script async defer> blocking HTML
nomoduleJS code (including the Safari hack)
<script type="module" src="module.js"></script> <script nomodule src="nomodule.js"></script>
Update September 2020: life's almost good. Edge Chromium is widely rolled out, and Safari 14.0 ships soon with a fix.
<script> async, defer, async defer, module, nomodule, src, inline- the cheat sheet
This document is a comparison of various ways the
<script> tags in HTML are processed depending on the attributes set.
If you ever wondered when to use inline
<script async type="module"> and when
<script nomodule defer src="...">, you're in the good place!
Note that this article is about
<script>s inserted in the HTML; the behavior of
<script>s inserted at runtime is slightly different - see Deep dive into the murky waters of script loading by Jake Archibald (2013)
-e:99and will have 99s worth of filmstrip images (while the test was shorter than that)
Re-run the testequivalent which allows changing config
Sometimes I have very elaborate test config which I want to reuse, but slightly change one thing (e.g. add one param to URL). I can easily re-run the test with exact same config, but it's not easy to slightly change config and re-run. You need to re-create the config from scratch by checking multiple checkboxes, and hoping you come up with same exact set of params as before
The correct behavior of all tools is to assume that
.js files are in ES modules format.
Hence you must convert existing
.js files (including config files) to ESM format, or rename them to
.cjs if you want to keep them intact.
You should rename
.cjs extension, or make them a valid JSON with .