Skip to content

Commit

Permalink
Update DOMLazyTree fragments comment to reflect reality
Browse files Browse the repository at this point in the history
  • Loading branch information
zpao committed Mar 11, 2016
1 parent 2326d1a commit 5a17a1e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/renderers/dom/client/utils/DOMLazyTree.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,10 @@ function insertTreeChildren(tree) {

var insertTreeBefore = createMicrosoftUnsafeLocalFunction(
function(parentNode, tree, referenceNode) {
// Document Fragments in IE11, Edge (and possibly others) won't update
// correctly if they are already inserted. So we have to break out of our
// lazy approach and append children to the fragment before inserting it.
// DocumentFragments aren't actually part of the DOM after insertion so
// appending children won't update the DOM. We need to ensure the fragment
// is properly populated first, breaking out of our lazy approach for just
// this level.
if (tree.node.nodeType === 11) {
insertTreeChildren(tree);
parentNode.insertBefore(tree.node, referenceNode);
Expand Down

0 comments on commit 5a17a1e

Please sign in to comment.