1
0
mirror of https://github.com/excalidraw/excalidraw.git synced 2025-02-18 13:29:36 +01:00

prevent exporting empty canvas

This commit is contained in:
dwelle 2020-01-02 18:19:00 +01:00
parent f091e9813e
commit 4eda1cfb5d

@ -34,6 +34,8 @@ function exportAsPNG({
exportVisibleOnly,
exportPadding = 10
}) {
if ( !elements.length ) return window.alert("Cannot export empty canvas.");
// deselect & rerender
clearSelection();