Merge pull request #5088 from chrisgarrity/export-custom-mimetype

Get the mime-type for the file from the blob
This commit is contained in:
chrisgarrity authored and GitHub committed 2019-08-13 15:22:58 -04:00
commit e9e07052f8
1 file changed
+1
+1
View File
@@ -11,6 +11,7 @@ export default (filename, blob) => {
const url = window.URL.createObjectURL(blob);
downloadLink.href = url;
downloadLink.download = filename;
downloadLink.type = blob.type;
downloadLink.click();
window.URL.revokeObjectURL(url);
document.body.removeChild(downloadLink);