react-canvas-draw icon indicating copy to clipboard operation
react-canvas-draw copied to clipboard

Fix useBgImage

Open mitjana opened this issue 3 years ago • 1 comments

The function called was not the right one

mitjana avatar May 05 '22 12:05 mitjana

I get this error trying to use this patch for getDataURL. The image seems to be empty, can you give an example on how you initialize & use getDataUrl?

Uncaught TypeError: Failed to execute 'drawImage' on 'CanvasRenderingContext2D': The provided value is not of type '(CSSImageValue or HTMLCanvasElement or HTMLImageElement or HTMLVideoElement or ImageBitmap or OffscreenCanvas or SVGImageElement or VideoFrame)'. at drawImageProp (drawImage.js:59:1) at CanvasDraw.getDataURL (index.js:124:1) at handleMouseOut (drawable-canvas.tsx:26:1)

kandabi avatar May 30 '22 11:05 kandabi