ensure null doesn't displace next siblings
This commit is contained in:
parent
2411303be8
commit
2f7c4983f3
2 changed files with 22 additions and 2 deletions
|
|
@ -879,4 +879,17 @@ o.spec("updateNodes", function() {
|
|||
|
||||
o(onupdate.callCount).equals(0)
|
||||
})
|
||||
o("null stays in place", function() {
|
||||
var vnodes = [{tag: "div"}, {tag: "a"}]
|
||||
var temp = [null, {tag: "a"}]
|
||||
var updated = [{tag: "div"}, {tag: "a"}]
|
||||
|
||||
render(root, vnodes)
|
||||
var before = vnodes[1].dom
|
||||
render(root, temp)
|
||||
render(root, updated)
|
||||
var after = updated[1].dom
|
||||
|
||||
o(before).equals(after)
|
||||
})
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue