Skip to content

Commit

Permalink
simpilify checking
Browse files Browse the repository at this point in the history
  • Loading branch information
clarkdo committed Jul 11, 2021
1 parent 15a3b04 commit e7b88fa
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/vue-app/template/client.js
Expand Up @@ -738,9 +738,8 @@ function hotReloadAPI(_app) {

if (_app.context.isHMR) {
const Components = getMatchedComponents(router.currentRoute)
const instances = getMatchedComponentsInstances(router.currentRoute)
instances.forEach((instance,index) => {
instance.constructor = Components[index]
Components.forEach((Component) => {
Component.prototype.constructor = Component
})
}
}
Expand Down

0 comments on commit e7b88fa

Please sign in to comment.