I'm encountering a specific CORS issue (please refer to the attached image for details). My application, built on a microservice architecture, utilizes Laravel for the backend and single-spa for the micro-frontend. I'm employing Vite for all micro-frontends and FilePond for image upload and preview. The image upload and retrieval of the image file URL are functioning correctly, but a specific CORS error is hindering the image from being displayed.
I'm uncertain about where to place the CORS header, whether in the API or the front end. Please see the attached screenshot for the issue. I would appreciate any assistance with this.
My expectation is for the image to be displayed when FilePond loads the image URL, without any CORS errors.
I solved my problem, I need to add htaccess in public subfolder screenshot with the value of:
<IfModule mod_rewrite.c>
<IfModule mod_headers.c>
Header always set Access-Control-Allow-Origin: "*"
</IfModule>
</IfModule>
Thank you guys