From 0004f25fea680e6e3c76446cc4dc59e90981f21e Mon Sep 17 00:00:00 2001 From: briandennis Date: Mon, 25 Sep 2017 08:27:36 -0500 Subject: [PATCH] append download link to DOM before downloading --- pages/editor.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pages/editor.js b/pages/editor.js index 0bf555a..9afa9dd 100644 --- a/pages/editor.js +++ b/pages/editor.js @@ -83,7 +83,9 @@ class Editor extends React.Component { const link = document.createElement('a') link.download = 'carbon.png' link.href = dataUrl + document.body.appendChild(link) link.click() + link.remove() }) }