-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Closed
Labels
Description
Dear Tauri Team,
I am trying to download a jar file and then save it with your provided funcation "writeBinaryFile". Unfortunately it does not work.
await axios({
url: '/downloads/client/latest.jar',
method: "GET",
responseType: "blob", // important
onDownloadProgress: (progressEvent) => {
setProgress(Math.round((progressEvent.loaded * 100) / progressEvent.total));
}
}).then(async value => {
const mcDir = await promisified({cmd: "minecraftDir"});
console.log(mcDir)
console.log(value)
console.log(value.data)
await writeBinaryFile({contents: value.data, path: mcDir + "/norisk/test.jar"}, {});
})
It creates an EMPTY + CORRUPTED File.
Whats the correct use?
Your sincerely,
Max
Reactions are currently unavailable