What is "documentfragment"

Documentfragment is an object that represents a minimal or simplified document in the DOM API available in browsers. Na represents a complete document, but rather a document snippet. It is an object that implements the interface Node.

Syntax

To create an empty Documentfragment:

var docFragment = document.createDocumentFragment();

where:

docFragment is a reference to the object DocumentFragment newly created.

References

  1. www.W3.org - Documentfragment interface
  2. Document Fragment - MDN Link