DocFrag - Clarify benefit

This commit is contained in:
2020-10-16 19:27:35 +05:30
parent ad594a2019
commit bde27f4cf6
+1 -1
View File
@@ -203,7 +203,7 @@ parent.insertBefore(newEle, ref.nextSibling)
### 6. Document Fragment
DocumentFragment can be considered to be a off-screen lightweight `document` object.
It is generally used for batching multiple operations - by doing them over time in the fragment and rendering it in one shot to the actual visible DOM.
It is generally used for batching multiple operations - by doing them in the fragment over time and then rendering the whole content to the visible DOM in one shot .
Because fragment is not rendered, making changes to it doesn't cause any performance impact (no reflow).