fix(transition): fix out-in transition getting stuck with v-if (#7023)

fix #6687
This commit is contained in:
Richard Musiol 2017-11-16 15:29:26 +01:00 committed by Evan You
parent a3246fd854
commit 45d7ba8429

View File

@ -161,7 +161,9 @@ export default {
oldChild &&
oldChild.data &&
!isSameChild(child, oldChild) &&
!isAsyncPlaceholder(oldChild)
!isAsyncPlaceholder(oldChild) &&
// #6687 component root is a comment node
!(oldChild.componentInstance && oldChild.componentInstance._vnode.isComment)
) {
// replace old child transition data with fresh one
// important for dynamic transitions!