GrapesJS / tui-image-editor

GrapesJS TOAST UI Image Editor
BSD 3-Clause "New" or "Revised" License
87 stars 37 forks source link

CORS Request #1

Closed yanosuke closed 1 year ago

yanosuke commented 5 years ago

Thank you for this great plugin. Everything has been working great until I made some changes to incorporate grapesJS into my platform. My clients are able to access GrapesJS from one subdomain, however, their images on stored on the clients' own subdomain. Because of this, a CORS request needs to be made. Server-side, everything is configured properly within .htaccess files, however, the request within this plugin needs to have "withCredentials = true" added. Is there an easy way to implement this so I am able to access images within this plugin?

Kuhreez commented 4 years ago

Hey @yanosuke , I'm looking at the toast UI docs, and it does not seem like their API lets you manipulate the header of the request for the image (see https://nhn.github.io/tui.image-editor/latest/ImageEditor#loadImageFromURL)

We use S3 on for my assets, and I was able to get around CORS issues by setting Access-Control-Allow-Origin from the server side.

This stackoverflow thread has good info on some troubleshooting steps that you may find useful https://stackoverflow.com/questions/54155431/toastui-image-editor-loadimagefromurl-doesnt-work

ghost commented 4 years ago

Hi !

I am running issues with cors also

image

i cant get the image to load in the modal

soscler commented 3 years ago

I also got the same issue with cors

artf commented 1 year ago

As mentioned by @Kuhreez this is not related to the plugin but to the image editor itself.