Files
explore/lib/downloadBlob.ts
tom a45aed6d0b csv export with old api
form fields

recaptcha v2

api integration

recaptcha reset

remove recaptcha key from git
2023-02-13 17:19:07 -05:00

11 lines
295 B
TypeScript

export default function downloadBlob(blob: Blob, filename: string) {
const url = URL.createObjectURL(blob);
const link = document.createElement('a');
link.setAttribute('href', url);
link.setAttribute('download', filename);
link.click();
link.remove();
URL.revokeObjectURL(url);
}