Quantcast
Channel: I am getting an "Invalid Host header" message when connecting to webpack-dev-server remotely - Stack Overflow
Viewing all articles
Browse latest Browse all 26

Answer by Lukas Kalbertodt for I am getting an "Invalid Host header" message when connecting to webpack-dev-server remotely

$
0
0

If you have not ejected from CRA yet, you can't easily modify your webpack config. The config file is hidden in node_modules/react_scripts/config/webpackDevServer.config.js. You are discouraged to change that config.

Instead, you can just set the environment variable DANGEROUSLY_DISABLE_HOST_CHECK to true to disable the host check:

DANGEROUSLY_DISABLE_HOST_CHECK=true yarn start  # or the equivalent npm command

Viewing all articles
Browse latest Browse all 26

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>