The Range interface represents a fragment of a document that can contain nodes and parts of text nodes in a given document.
- The Range.collapsed read-only property returns a Boolean flag indicating whether the start and end points of the Range are at the same position. It returns true if the start and end boundary points of the Range are the same point in the DOM, false if not.
- Returns the deepest node in which two boundary points exist.
- Retrieves the end point node of the current range.
- Returns a number representing where in the Range.endContainer the Range ends.
- Retrieves the starting node of a current range
- Retrieves the offset of the starting boundary point relative to the startContainer in the current range.
- Returns a document fragment containing the nodes of a range. If any nodes are partially selected, their start or end nodes are included.
- Returns a new range with boundary points that are equal to the original range.
- Collapses (or removes) a range by moving the insertion point to the beginning or end of the current range.
- The Range.compareBoundaryPoints() method compares the boundary points of the Range with another one.
- Removes all contents within a selected range.
- Removes or detaches a Range object and associated resources form a document.
- Removes the contents of a range from a document or document fragment and puts it a new document fragment.
- Inserts a Node into the start of a Range object.
- Selects a range node and all of its contents.
- Sets the Range to contain the contents of a Node.
- Sets the end point of the range.
- Sets the end of a range to a point after a specific node.
- Sets the end of the range to a point before a specific node.
- Sets the starting point of a range
- Sets the starting point of the range to a point after a specific node.
- Sets the start point of a range to a point before a specific node.
- Moves the contents of a Range to a new parent node, placing the new parent node at the start position of the Range.
- Returns the contents of a Range as a string. This string contains only the data characters, no markup.
- CSS Object Model - View Module
- Working Draft
- DOM Parsing and Serialization
- Living Standard
- Living Standard