f / f/graphql.js

Headers not working (credentials: 'included'?)

Open
#63 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
2.3k
Forks
88
PR merge metrics
No merged PRs in 30d

Description

Hello,

The backend is attempting to set a cookie by using a cookie request. Typically, in front end applications one uses credentials: true or credentials: "included" which then sets the cookie, but this does not seem to be working. In the network tab, I can see the cookie request come in, yet it never actually sticks as a cookie. What setting should I use in my headers to enable credentials?

```js
var graph = graphql("http://localhost:3000/api/graphql", {
headers: {
credentials: "include",
"Authorization": "",
},
asJSON: true,
});
```

Thank you

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.