download button
This commit is contained in:
9
src/functions/downloadFile.ts
Normal file
9
src/functions/downloadFile.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
function downloadFile(uri:string): void {
|
||||
const link = document.createElement("a")
|
||||
link.download = ""
|
||||
link.href = uri
|
||||
link.click()
|
||||
link.remove()
|
||||
}
|
||||
|
||||
export default downloadFile
|
||||
Reference in New Issue
Block a user