Message from JavaScript discussions

September 2020

— Https://groups.google.com/a/chromium.org/g/blink-dev/c/GbVcuwg_QjM
regarding chrome blocking data uris

Message permanent page

— 

What i’m trying to achieve is print a custom html doc without blocking the page interaction, as i have idb transactions open and i dont want them to be aborted due to timeout

— The user has to click the pop-up once

— Currently i’m doing this:

var newWin= window.open("",'','target=_blank');
newWin.document.write(result);
newWin.document.close()


where result is html as string and the following script at the end:

window.print();
window.close();

Message permanent page

— document.close is not a function btw afaik

— It is

— Oh, what does it do?

— It closes the input stream, so that the written changes are reflected in dom

— Also I had a similar problem with the data URI and I fixed via corsproxy

— Input stream opened by write

— Til

— The thing that is confusing me is why is the popup in other tab blocking the parent tab