diff options
Diffstat (limited to '')
-rw-r--r-- | dom/base/test/file_script_module_import_multi_elems_1.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/dom/base/test/file_script_module_import_multi_elems_1.js b/dom/base/test/file_script_module_import_multi_elems_1.js new file mode 100644 index 0000000000..11648d3d1a --- /dev/null +++ b/dom/base/test/file_script_module_import_multi_elems_1.js @@ -0,0 +1,14 @@ +import { f } from "./file_script_module_import_multi_elems_imported_once_1.js"; +import { h } from "./file_script_module_import_multi_elems_imported_twice.js"; +f(); +h(); + +// Dynamically insert the element after loading all source, so that +// the module import doesn't race. +const script = document.createElement("script"); +script.id = "watchme2"; +script.setAttribute("type", "module"); +script.setAttribute("src", "file_script_module_import_multi_elems_2.js"); +document.body.appendChild(script); + +window.dispatchEvent(new Event("test_evaluated")); |