Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- export default (uri, fileName) => {
- const link = document.createElement('a');
- link.download = fileName;
- link.href = uri;
- link.target = '_blank';
- document.body.appendChild(link);
- link.click();
- document.body.removeChild(link);
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement