Function: downloadMedia()
downloadMedia(
source,filename):void
Defined in: media/utils.ts:80
Request a browser download of a file URL or Blob from a user interaction. URL strings are linked directly without fetching. Cross-origin URLs may open in a new tab unless the server serves them as attachments. Fetch a Blob first when CORS permits it and the filename/download behavior must be controlled. Only URLs created here are revoked, after a short browser handoff period. This requests a download; it cannot observe whether the browser saves the file.
Parameters
source
string | Blob
A file URL or already fetched/encoded bytes.
filename
string
Suggested filename, including its extension.
Returns
void