Skip to content

SelectionRange.map method

SelectionRange › map

Official

Map this range through a change, producing a valid range in the updated document.

Signature:

map(change: ChangeDesc, assoc?: number | undefined): SelectionRange

Parameters:

Parameter Type Description
change ChangeDesc The change description.
assoc? number | undefined Which side the position is associated with.

Returns: SelectionRangeThe mapped selection range.