提交 a9c0ae34 编写于 作者: N nkzawa

use webpack/hot/dev-server to full-reload on HMR errors

上级 165431bd
......@@ -13,7 +13,7 @@ export default async function createCompiler (dir, { hotReload = false } = {}) {
const pages = await glob('pages/**/*.js', { cwd: dir })
const entry = {}
const defaultEntries = hotReload ? ['webpack/hot/only-dev-server'] : []
const defaultEntries = hotReload ? ['webpack/hot/dev-server'] : []
for (const p of pages) {
entry[join('bundles', p)] = defaultEntries.concat(['./' + p])
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册