0

I am using PDF JS demo app and I give a base64 pdf from the server to the viewer. This does work very good on chrome and mozilla(both desktop and mobile) but it doesn't work at all on Safari.

I think the issue is because of the XHR but I don't have that much experience so I can't say for sure.

What are my alternatives ?

2 Answers2

1

I resolved this by converting the base64 to binary with atob.

0

atob does not work in my case, I used this to convert base64 to binary array Pdf.js: rendering a pdf file using a base64 file source instead of url

Community
  • 1
  • 1
Tung Do
  • 1,423
  • 3
  • 13
  • 27