What I mean is to make an html In a new window
You can set a variable equal to a new blank window opened, then take that window and write inside of its document some HTML code.
var a = window.open();
a.document.write(`
<!-- TYPE HTML CODE HERE -->
`);
Let me know if this isn’t what you meant.