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

Add ability to use multiple proxies for development #1780

Closed
mwq27 opened this issue Mar 9, 2017 · 6 comments · Fixed by #1790
Closed

Add ability to use multiple proxies for development #1780

mwq27 opened this issue Mar 9, 2017 · 6 comments · Fixed by #1790

Comments

@mwq27
Copy link

mwq27 commented Mar 9, 2017

I want to be able to pass in multiple proxies in my package.json, instead of just one string.

@gaearon
Copy link
Contributor

gaearon commented Mar 9, 2017

Okay, I agree it’s probably worth supporting it. It’s been requested multiple times.
It would be good to also solve #1702 while we’re at it.

Do you have a proposed format? Should we use the same format WebpackDevServer uses? Perhaps we should also do #671 as a part of this.

Happy to review PRs.

@mwq27
Copy link
Author

mwq27 commented Mar 10, 2017

I was thinking that what can be passed into the proxy property is an object, like webpackdevServer.

{
  ...
  "proxy": {
    "/myApiUrl": {
            target: 'http://some.target.com:4000',
            changeOrigin: true
        }
  }
  ...
}

@jamesblight
Copy link
Contributor

jamesblight commented Mar 11, 2017

@gaearon I've made a PR for this when you get time #1790

@Rkiouak
Copy link

Rkiouak commented May 11, 2017

Would love to see this merged in, james PR looks great

@Timer
Copy link
Contributor

Timer commented May 15, 2017

🎆

@gaearon
Copy link
Contributor

gaearon commented May 16, 2017

Please help beta test the new version that includes this change!
#2172

@lock lock bot locked and limited conversation to collaborators Jan 21, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants