test: update fragment tests

This commit is contained in:
Evan You
2019-08-23 15:27:17 -04:00
parent 589d3c2feb
commit fd1fef5502
9 changed files with 343 additions and 194 deletions

View File

@@ -694,7 +694,9 @@ export function createRenderer(options: RendererOptions) {
if (prevShapeFlag & ShapeFlags.ARRAY_CHILDREN) {
unmountChildren(c1 as VNode[], parentComponent)
}
hostSetElementText(container, c2 as string)
if (c2 !== c1) {
hostSetElementText(container, c2 as string)
}
} else {
if (prevShapeFlag & ShapeFlags.TEXT_CHILDREN) {
hostSetElementText(container, '')