Open tinachi7 opened 1 year ago
You have to use QuillImageDropAndPaste.ImageData instead of the builtin ImageData in the browser.
So, if you had above import QuillImageDropAndPaste from 'quill-image-drop-and-paste'
it should be
imageHandler(dataUrl, type, new QuillImageDropAndPaste.ImageData(dataUrl, type, name));
Trying to implement the toolbar image handler to compress images with this package but I keep getting the error “Failed to construct ImageData:the provided value is not of type ImageDataSettings at reader.load”
also tried using the exact code from example sample from documentation but get same exact error. btw my console logged values match the console logs from the imageData values from the imageHandler for drop and paste, which are working fine.