Skip to content

Commit

Permalink
fix(hmr): should update el for HYDRATE_EVENTS patchFlags node (#1707)
Browse files Browse the repository at this point in the history
  • Loading branch information
underfin authored Jul 28, 2020
1 parent 421a70d commit de62cc0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/runtime-core/src/renderer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2105,7 +2105,7 @@ function baseCreateRenderer(
const c1 = ch1[i] as VNode
const c2 = (ch2[i] = cloneIfMounted(ch2[i] as VNode))
if (c2.shapeFlag & ShapeFlags.ELEMENT && !c2.dynamicChildren) {
if (c2.patchFlag <= 0) {
if (c2.patchFlag <= 0 || c2.patchFlag === PatchFlags.HYDRATE_EVENTS) {
c2.el = c1.el
}
traverseStaticChildren(c1, c2)
Expand Down

0 comments on commit de62cc0

Please sign in to comment.