erikras / erikras/react-redux-universal-hot-example

[api-proxy] 'set-cookie' missing in response

Open
#1,067 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
12.1k
Forks
2.5k
PR merge metrics
No merged PRs in 30d

Description

Anyone else experiencing problems with 'set-cookie' header?

If I add this lines on `src/server.js`

``` javascript
proxy.on('proxyRes', (proxyRes) => {
console.log('RAW', JSON.stringify(proxyRes.headers, true, 2));
});
```

I can see `set-cookie` header there, but once I try to access it on `src/helpers/ApiClient.js`, I can't find it.

``` javascript
// request.end((err, { body } = {}) => err ? reject(body || err) : resolve(body));
request.end((err, res) => {
if (err) {
reject(res.body || err);
} else {
console.log('HEADERS', res.headers);
resolve(body));
}
});
```

`set-cookie` is the only header missing.

Am I doing something wrong?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.