fix(版本对比): 对比算法补充

--user=郭雨琦
This commit is contained in:
guoyuqi 2022-03-29 14:44:38 +08:00 committed by 刘瑞斌
parent edaee7da55
commit 45f21830c1
1 changed files with 5 additions and 1 deletions

View File

@ -233,13 +233,17 @@ function sameDetail(oldVnode,newVnode,sameNode){
}else{
sameNode.nodeArray = [];
}
}else if(oldVnode.tag==='textarea'&&newVnode.tag==='textarea'){
}
else if(oldVnode.tag==='textarea'&&newVnode.tag==='textarea'){
if(oldVnode.elm.value===newVnode.elm.value){
sameNode.nodeArray.push(newVnode.elm);
}else {
sameNode.nodeArray = [];
}
}
else {
sameNode.nodeArray.push(newVnode.elm);
}
}
else {
if(sameVnode(oldVnode,newVnode)){