Generated File doesnt have images that were present on the webpage.
ishanavasthi opened this issue · 3 comments
ishanavasthi commented
tipsytime commented
You can also try changing the CORS settings for html2canvas when implementing:
`let opt = {
image: { type: 'jpeg', quality: 0.98 },
html2canvas: { scale: 2, useCORS: true}
};
html2pdf().set(opt).from(element).save();`
kurkurzz commented
This unfortunately not works. I'm not sure why but the image itself is hosted on S3 with appropriate permissions. This is the error I got:
from origin 'http://localhost:3000' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
Any idea how to fix this?
update: turns out it works fine on Mozilla but failing in Chrome.