Skip to content

Commit

Permalink
fix: update hmr api usage
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Nov 20, 2020
1 parent 4ad1be9 commit f9dd610
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hotReload.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if (module.hot) {
script.__hmrId = "${id}"
const api = __VUE_HMR_RUNTIME__
module.hot.accept()
if (!api.createRecord('${id}')) {
if (!api.createRecord('${id}', script)) {
api.reload('${id}', script)
}
${templateRequest ? genTemplateHotReloadCode(id, templateRequest) : ''}
Expand Down

0 comments on commit f9dd610

Please sign in to comment.