Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /svg/interact/scripted/async-04.html - WPT Dashboard Interop Dashboard
<html>
<head>
<title>Check async script state matches attribute</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<svg>
<script id="script" async href="data:text/javascript, // Do nothing."></script>
<script>
test(function() {
let script = document.getElementById("script");
script.remove();
assert_true(script.async, "script is async");
script.removeAttribute("async");
assert_false(script.async, "script is no longer async");
}, "async script state");
</script>
</svg>
</body>
</html>