pqina / filepond-plugin-image-preview

🖼 Show a preview for images dropped on FilePond
https://pqina.nl/filepond
MIT License
46 stars 26 forks source link

Support for using img tag instead of canvas #38

Closed cloydlau closed 3 years ago

cloydlau commented 4 years ago

CORS permission will be required when using canvas tag and ajax request for image url. But it's not convenient especially dealing with some third-party APIs. And not just CORS issues, If you're requesting for a http protocol image url under a https domain, browser security policy will not allow this. So it will be very helpful if there is an option I can choose which tag to load image and feasibility to avoid ajax request after uploading. Actually, image upload libs like 'uppy', 'dropzone', 'element-ui', 'ant design', etc are all using img tag, so CORS support is not necessary.