applyTextEdits
applyTextEdits(
source,edits):string
Defined in: packages/core/src/string/apply-text-edits.ts:25
Applies a set of TextEdits to source.
Edits must be non-overlapping. Applies in descending offset order to avoid invalidating subsequent offsets.
Parameters
Section titled “Parameters”source
Section titled “source”string
The source string to apply edits to
TextEdit[]
The edits to apply
Returns
Section titled “Returns”string
The modified string after applying the edits