I have a base64 string and i want to view it in my reactjs website. I used tag and tag and both are working fine in development, but in production the file does not load.
i tried both and both work in development and are being rendered but in development when i upload my website to the server it does not load
Why is that?
Here is my code:
//documentContent is my base64 string
<embed src={`data:application/pdf;base64,${documentContent}`} />
<object data={`data:application/pdf;base64,${documentContent}`} type="application/pdf" width="100%" height="100%"/>