Type Editor / @type-editor/dom-util / text-range
text-range
Functions
| Function | Description |
|---|---|
Clears the reused Range object. This should be called when you need to ensure the cached Range is properly released, particularly when switching contexts or cleaning up resources. Example typescript | |
Creates or reuses a DOM Range for a text node. Note: This function always returns the same Range object for performance reasons. DOM Range objects are expensive to create and can slow down subsequent DOM updates. Call Example typescript |