OLD | NEW |
(Empty) | |
| 1 <!doctype html> |
| 2 <html> |
| 3 <head> |
| 4 <title>html-script-module-errorHandling-parseError-DependentMultiple</title> |
| 5 <script src="errorhandling-parseerror-common.js"></script> |
| 6 </head> |
| 7 <body> |
| 8 <script type="module" onerror="errorHandler(event);createSecondDependentRoot
();"> |
| 9 |
| 10 // No parse errors in the root module, just in the dependent module |
| 11 import test from "./errorhandling-parseerror-dependentmultiple.js"; |
| 12 document._errorReported = "shouldn't have run dependent module"; |
| 13 |
| 14 </script> |
| 15 <script> |
| 16 |
| 17 function createSecondDependentRoot() |
| 18 { |
| 19 // With the broken dependent module already acquired, try to import
it |
| 20 // again from another root. This root should be unwound appropriate
ly. |
| 21 var script = document.createElement("script"); |
| 22 script.type = "module"; |
| 23 script.textContent = "import test from './errorhandling-parseerror-d
ependentmultiple.js';" + |
| 24 "document._errorReported = 'really shouldn\\'t
have run dependent module';"; |
| 25 script.addEventListener("error", errorHandler); |
| 26 document.body.appendChild(script); |
| 27 } |
| 28 |
| 29 </script> |
| 30 </body> |
| 31 </html> |
OLD | NEW |