Matt-Esch / virtual-dom

A Virtual DOM and diffing algorithm
MIT License
11.67k stars 777 forks source link

diff-algorithm generates patch with null-node - patch cannot handle null-nodes #268

Closed pwde closed 9 years ago

pwde commented 9 years ago

Hello,

first: thanks for virtual-dom.

I run into an strange issue in v2.0.0 with keyed rows in a table - I think it is a bug:

    var patch = virtualDom.diff(vdomOld, vdom);

    domNode = virtualDom.patch(domNode, patch);

I hope, it can be fixed.

Regards, Peter.

neonstalwart commented 9 years ago

can you provide us with a test case that will consistently reproduce this? working from screenshots isn't really going to help us since we probably need to know how the null got there to begin with and seeing that it's there doesn't help us know how it got there.

pwde commented 9 years ago

OK, I'll try to extract a simple test-case... from a complex vdom-tree...

pwde commented 9 years ago

Oh, I found a bug in my code... sorry... a key was used twice.