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

Option to change port in webpackHotDevClient #2003

Closed
dan-weaver opened this issue Apr 20, 2017 · 2 comments
Closed

Option to change port in webpackHotDevClient #2003

dan-weaver opened this issue Apr 20, 2017 · 2 comments

Comments

@dan-weaver
Copy link

dan-weaver commented Apr 20, 2017

Hi thanks for everyone's work on this project so far.

Quick question. I've run into some configuration woes wherein I need webpackHodDevClient to use a different port for the websocket connection Currently, it infers the information for the sockjs connection from window.location.port. The trouble I'm running into is that my index.html is being served from a different port than the webpack dev server is running on. For more specific background, I'm migrating from a configuration like this: http://jmfurlott.com/tutorial-setting-up-a-simple-isomorphic-react-app/. I have a small NodeJS server that acts as an oAuth client and provides a few endpoints to my react app. It therefore needs to serve index.html itself rather than serving the static index.html that ships with CRA.

I have already ejected, as my above use case is pretty specific. What I'm wondering is if CRA should provide some kind of option (I may be overlooking it) to affect this configuration within webpackHotDevClient or should it otherwise include the client in the ejected contents such as the scripts and config files.

Sorry if this is at all redundant I combed through issues and couldn't find anything quite like this. Also quite possible I'm not taking advantage of some features of CRA that may help me avoid this situation altogether?

@viankakrisna
Copy link
Contributor

will this help? #1994

@dan-weaver
Copy link
Author

@viankakrisna Yes I think either that or #1588 will solve my issue thank you for pointing this out.

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

No branches or pull requests

2 participants