customize-cra: overrideDevServer does not work
here is the config-overrides.js (omitted require sentences)
const devServerConfig = () => config => {
return {
...config,
port: 3001
}
}
module.exports = {
webpack: override(
fixBabelImports('import', {
libraryName: 'antd',
libraryDirectory: 'es',
style: 'css'
}),
useBabelRc()
),
devServer: overrideDevServer(devServerConfig())
}
But the port devServer uses is still 3000, not 3001
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 3
- Comments: 21
遇到同样问题,修改不了devServe的配置
here is my config file, it can proxy 3005 port while my frontend app is running at port 3000
The proxy works, but if the port is not 3000, the port still does not work. You can try to change port to 3001