MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / rebaseHist

Function rebaseHist

lib/web/CodeMirror/src/model/changes.js:323–327  ·  view source on GitHub ↗
(hist, change)

Source from the content-addressed store, hash-verified

321}
322
323function rebaseHist(hist, change) {
324 let from = change.from.line, to = change.to.line, diff = change.text.length - (to - from) - 1
325 rebaseHistArray(hist.done, from, to, diff)
326 rebaseHistArray(hist.undone, from, to, diff)
327}
328
329// Utility for applying a change to a line by handle or number,
330// returning the number and optionally registering the line as

Callers 2

makeChangeInnerFunction · 0.70
makeChangeFromHistoryFunction · 0.70

Calls 1

rebaseHistArrayFunction · 0.70

Tested by

no test coverage detected