3 ms·
We are only talking about the DOM and not about frameworks. DocumentFragments empty their contents when appended. This is standard DOM behavior. To "reuse" a D
by spankalee 1y ago
We are only talking about the DOM and not about frameworks.
DocumentFragments empty their contents when appended. This is standard DOM behavior. To "reuse" a DocumentFragments after appending it somewhere you have to repopulate it with _new_ DOM, which is no different from creating a new fragment.
At that point are you really arguing that you can keep a container and keep refilling it and that counts as reuse in the sense we mean? Reuse in spirit is reusing the DOM in the container, not jus the empty container.