This repository has been archived by the owner on Feb 18, 2024. It is now read-only.
Add RFC forwarded header as hint to backend server #1139
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #1089
changeOrigin: true
Quickly looking around, it seems like it causes confusion no matter which way you default it:
changeOrigin
set to true by default facebook/create-react-app#4302Originally I was inclined to remove it just to keep the defaults from webpack-dev-sever, as I was the one who added it, and since am not sure why I needed it 😝
However, it seems like perhaps it is more useful as
true
for more people?CRA, for example, sets this to
true
, but then again there are people asking that they don't.So, I left it as-is. Seems maybe like a toss-up. Any input welcome.
X-Dev-Server-Proxy
/Forwarded
This PR removes the invented/non-standard
X-Dev-Server-Proxy
in favor of aForwarded
header to indicate to the proxied server that this request has been proxied by webpack-dev-server.I think I've read this too many times and proxies, being proxies, confuse me quickly…
I'm not 💯 if this should be
for:
orby:
. Anyone good at reading spec-language? 😁