Closed joshgillies closed 7 years ago
TL;DR 0.15.3
fixes this
The node wasn't re-rendered, simply re-appended.
This was caused by different handling of single virtual node, a situation where you have a node in between others instead of as content (the faster and more common any node case).
However, the logic should've been the same used for an array of nodes, but it wasn't.
0.15.3
now uses exact same logic resulting in actually slightly smaller final size and consistent results :tada:
Thanks for filing the bug.
Awesome, really impressive work @WebReflection 👌
Sorry for the awkward issue title, I wasn't entirely sure how to describe it best. Feel free to update if there's something more appropriate.
Anyways, for this I feel like the code speaks for itself. In the following example the
hyperHTML.wire(model, ':ul')
wire, will always re-render.Note the above yields the expected results (no re-rendering of any node) if
hyperHTML.wire(model, ':ul')
is wrapped in a parent node, eg.<div>hyperHTML.wire(model, ':ul')...</div>
.