let newWindow = open('/', 'example', 'width=300,height=300');
newWindow.onload = function() {
newWindow.close();
alert(newWindow.closed); // true
};
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.