image icon indicating copy to clipboard operation
image copied to clipboard

Image not showing after response

Open fab679 opened this issue 4 years ago • 4 comments

I'm uploading my image to the backend and returning the json format as written in the docs, but it keeps loading and not displaying the Image. It's just Loading. What could be the issue?

fab679 avatar Jul 10 '21 16:07 fab679

Are there any errors in a console?

neSpecc avatar Aug 16 '21 16:08 neSpecc

Are there any errors in a console?

I have the same problem. there are no errors because the page reloads automatically but the image is uploaded to the backend alright but does not show in the blocks

SsadiqRoy avatar Oct 09 '21 08:10 SsadiqRoy

In my case image data wasn't uploading correctly, thus the browser wasn't firing the load event for invalid image. Looks like this can be handled by listening for the error event.

https://developer.mozilla.org/en-US/docs/Web/API/Element/error_event

https://github.com/editor-js/image/blob/e3df500fc62a88d3490fa4ba4030c07f0cd79d64/src/ui.js#L197-L211

ibrahimduran avatar Oct 12 '21 10:10 ibrahimduran

I think it either the file didn't upload correctly or it because the problem/miscalculation about how you get the url from the database. It happens to me because it is my fault when patch the url incorrectly, so you can double-check the url when you patch the url like maybe you opened a wrong value that make it didn't appear or anything else and also put it into your img tag or background image.

Hope it helps. Goodluck!

edricgalentino avatar Apr 23 '22 03:04 edricgalentino