MCPcopy
hub / github.com/basecamp/trix / getDocumentAtRange

Method getDocumentAtRange

src/trix/models/document.js:435–439  ·  view source on GitHub ↗
(range)

Source from the content-addressed store, hash-verified

433 }
434
435 getDocumentAtRange(range) {
436 range = normalizeRange(range)
437 const blocks = this.blockList.getSplittableListInRange(range).toArray()
438 return new this.constructor(blocks)
439 }
440
441 getStringAtRange(range) {
442 let endIndex

Callers 6

getStringAtRangeMethod · 0.95
getSelectedDocumentMethod · 0.80
getAttachmentAtRangeMethod · 0.80
assertions.jsFile · 0.80
trix.jsFile · 0.80

Calls 3

normalizeRangeFunction · 0.90
toArrayMethod · 0.45

Tested by

no test coverage detected