You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This app has the CORS filter enabled which, since GraphiQL app sends the header "Origin:null", makes POST requests fail. I know GraphiQL is embedded in a template but I was trying to debug why my custom app wasn't working in GraphiQL so download this repo to make sure I wasn't missing anything and lo and behold! GraphiQL doesn't work here either. After some trial and error, finally understood that the problem was the Origin header that GraphiQL was sending...
So to save other people'e time, a small note in the documentation would be nice. For example, something like this:
Warning to GraphiQL app users
Due to the fact that GraphiQL sends the Origin header as null (see skevy/graphiql-app#53), in apps that have CORS enabled, POST requests won't work. Either use the embedded GraphiQL view or disable CORS.
Thanks a lot for Sangria by the way :)
The text was updated successfully, but these errors were encountered:
Hi,
This app has the CORS filter enabled which, since GraphiQL app sends the header "Origin:null", makes POST requests fail. I know GraphiQL is embedded in a template but I was trying to debug why my custom app wasn't working in GraphiQL so download this repo to make sure I wasn't missing anything and lo and behold! GraphiQL doesn't work here either. After some trial and error, finally understood that the problem was the Origin header that GraphiQL was sending...
So to save other people'e time, a small note in the documentation would be nice. For example, something like this:
Warning to GraphiQL app users
Due to the fact that GraphiQL sends the Origin header as null (see skevy/graphiql-app#53), in apps that have CORS enabled, POST requests won't work. Either use the embedded GraphiQL view or disable CORS.
Thanks a lot for Sangria by the way :)
The text was updated successfully, but these errors were encountered: