eligrey / FileSaver.js

An HTML5 saveAs() FileSaver implementation
https://eligrey.com/blog/saving-generated-files-on-the-client-side/
Other
21.54k stars 4.38k forks source link

Version 2+ does not work with Chrome popup blocker extension #561

Open cosme-benito opened 5 years ago

cosme-benito commented 5 years ago

From version 2.0 forward, every time the user tries to download a file, a popup notification shows up and the file doesn't download (even if the user presses the "show popup" or "whitelist this site" button). This does NOT happen with version 1.3.8.

I managed to reproduce this problem by using the "Poperblocker' extension, which can be found here: https://poperblocker.com/

JSFiddle with 2.0.2: https://jsfiddle.net/sdu4xcne/1/

JSFiddle with 1.3.8: https://jsfiddle.net/qeujogs4/

micahjon commented 5 years ago

I created a PR which fixes this issue. I don't love the solution since it's a bit obscure, but it is simple and fixes the conflict with this Chrome extension.

joriswitteman commented 2 years ago

Was the PR for this merged, or does this problem still exist? Looks like Safari still sees FileSaver.saveAs() as a pop-up window (like a window.open).

cosme-benito commented 2 years ago

Nop, as you can see it's still open !568