eligrey / FileSaver.js

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

.txt download from different browers on phone that filename is not correct name.but PC browers is correct. #788

Open wobushidaxingxing opened 1 year ago

wobushidaxingxing commented 1 year ago
var fileName = $('.selectpicker select option:checked').text() + ".txt"
var blob = new Blob([tempAreaDef], { type: "text/plain;charset=utf-8" });
saveAs(blob, fileName);
mk-fault commented 1 year ago

i got the same question,and on some mobile browers,the blob even cant be download successfully