mirror of
https://github.com/status-im/MyCrypto.git
synced 2025-01-10 11:05:47 +00:00
37008e9fe9
* GenerateWallet: Download real UTC file. * Paper wallet (#45) * Working paper wallet (#52) * Reset Generate Wallet state when component will unmount
10 lines
263 B
JavaScript
10 lines
263 B
JavaScript
// @flow
|
|
export function makeBlob(mime: string, str: string | Object) {
|
|
str = typeof str === 'object' ? JSON.stringify(str) : str;
|
|
if (str === null) return '';
|
|
const blob = new Blob([str], {
|
|
type: mime
|
|
});
|
|
return window.URL.createObjectURL(blob);
|
|
}
|