I'm generating a file client-side, I have the data in hexadecimal and just want to let the user download the generated file.
var blob = new Blob([hexData], {type: "application/octet-stream"});
console.log(URL.createObjectURL(blob));
The resulting file is a plain-text file containing hex data in ASCII. How can I force the Blob to contain the binary data as is and not as text?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…