deleteContents

The Range.deleteContents() method removes all completely-selected Node within this range from the document.

MDN Reference