Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In Transport constructor, allow modification of all fetch options, not just headers #1

Open
jimthedev opened this issue Dec 23, 2015 · 4 comments

Comments

@jimthedev
Copy link

The fetch key is, as far as I can tell, set to 'include' without a way of overriding the value. At times during development it may be necessary to use an Access-Control-Origin of *. This will not work if credentials are sent over the wire so until we can configure the credentials value to be undefined, there is no way to work with wildcard cors.

@arunoda
Copy link
Contributor

arunoda commented Dec 23, 2015

Check this.
https://github.com/arunoda/learn-redux/blob/server-side/server/graphql.js#L8

Basically, it's like wildcard.
Let me know, if that's work for you. If not, let's make some changes.

@acyuta108
Copy link

I submitted a pull request allowing to add mode to options param which is somewhat related to this issue. I also advised we could actually allow options param to be fully compatible with isomorphic-fetch.

@tkers
Copy link

tkers commented May 18, 2016

Additionally it would be nice to set the rejectUnauthorized flag (to ignore self signed certificates in development, when doing server side rendering) which is, in node-fetch, passed down by setting a custom agent (an instance of https.Agent) in the options.

To me it looks like it would be perfectly fine to simply assign the options to this._httpOptions in this line, or am I missing something?

@barbalex
Copy link

https://github.com/arunoda/learn-redux/blob/server-side/server/graphql.js#L8 will not work for me as I am using https://github.com/calebmer/postgraphql.

Is there a way to prevent credentials to be sent?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants