<!DOCTYPE html> | |
<!-- | |
| The EventTarget() constructor, when invoked, must return a new EventTarget. | |
| https://dom.spec.whatwg.org/#dom-eventtarget-eventtarget | |
--> | |
<html> | |
<head> | |
<style> | |
body { | |
background-color: red; | |
} | |
body.event-target-is-constructible { | |
background-color: green; | |
} | |
</style> | |
</head> | |
<body> | |
<script> | |
new EventTarget(); | |
document.body.classList.add('event-target-is-constructible'); | |
</script> | |
</body> | |
</html> |