react-hot-loader fixbug
2017-10-15 本文已影响0人
娜小花
[HMR] Update check failed: Error: Failed to execute 'open' on 'XMLHttpRequest': Invalid URL
console 2017-10-15 下午5.02.13.pngpackage.config.js
module.exports = {
output: {
publicPath: 'http://localhost:3001'
}
}
纠错:
publicPath路径那里丢失了一个语法斜杠
module.exports = {
output: {
path: path.join(__dirname,'/dist/'),
filename: '[name].js',
publicPath: 'http://localhost:3001/'
}
}