react-pdf icon indicating copy to clipboard operation
react-pdf copied to clipboard

Not Able to Show Image in Generated PDF in React-PDF.

Open Yassyn90 opened this issue 1 year ago • 4 comments

I tried many different methods to show the image the in the generated pdf file using React-PDF, but none of them worked for me.

Yassyn90 avatar Aug 25 '23 18:08 Yassyn90

Same here.

Nothing works.

In fact the html seems to be rendering an <image /> tag instead of an <img />, that's probably why, as that's not valid.

MartinDawson avatar Sep 02 '23 14:09 MartinDawson

It works fine for me. Which file formats do you use? Only JPEG and PNG are supported.

If the format is correct, do you use images, that can be accessed from any host?

Wegi avatar Sep 06 '23 12:09 Wegi

Please provide the image you have issues with and a way to replicate this

diegomura avatar Feb 03 '24 18:02 diegomura

i had issue with jpeg/jpg, while png works with Image and img component. Seems like data stream from jpeg is much different from png and on opening pdf it can't read it

tested on webp, not working same way

marsidorowicz avatar Feb 25 '24 17:02 marsidorowicz