MCPcopy Create free account
hub / github.com/Rich-Harris/magic-string / between

Method between

tests/fuzz/edit-model.ts:144–149  ·  view source on GitHub ↗
(start: number, end: number)

Source from the content-addressed store, hash-verified

142 }
143
144 private between(start: number, end: number): string {
145 let result = ''
146 for (let c = start; c < end; c++)
147 result += this.right[c] + this.text[c] + this.left[c + 1]
148 return result
149 }
150
151 private isInsideHolder(index: number): boolean {
152 return this.holderEnd.some((holderEnd, h) => this.text[h] !== '' && h < index && index < holderEnd)

Callers 3

toStringMethod · 0.95
lengthMethod · 0.95
sliceMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected