MCPcopy Create free account
hub / github.com/experdot/pointer / downloadBlob

Function downloadBlob

src/renderer/src/utils/screenshot.ts:75–84  ·  view source on GitHub ↗
(blob: Blob, filename: string)

Source from the content-addressed store, hash-verified

73 * Download a Blob as a file
74 */
75export function downloadBlob(blob: Blob, filename: string): void {
76 const url = URL.createObjectURL(blob)
77 const link = document.createElement('a')
78 link.href = url
79 link.download = filename
80 document.body.appendChild(link)
81 link.click()
82 document.body.removeChild(link)
83 URL.revokeObjectURL(url)
84}
85
86/**
87 * Copy image to clipboard

Callers 1

exportStore.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected