MCPcopy Index your code
hub / github.com/tinyplex/tinybase / addCheckpointImpl

Function addCheckpointImpl

docs/pseudo.esm.sh/tinybase@9.0.0/index.js:507–517  ·  view source on GitHub ↗
(label = EMPTY_STRING)

Source from the content-addressed store, hash-verified

505 let cellListenerId;
506 let valueListenerId;
507 const addCheckpointImpl = (label = EMPTY_STRING) => {
508 if (isUndefined(currentId)) {
509 currentId = EMPTY_STRING + nextCheckpointId++;
510 mapSet(deltas, currentId, [cellsDelta, valuesDelta]);
511 setCheckpoint(currentId, label);
512 cellsDelta = mapNew();
513 valuesDelta = mapNew();
514 checkpointsChanged = 1;
515 }
516 return currentId;
517 };
518 const goBackwardImpl = () => {
519 if (!arrayIsEmpty(backwardIds)) {
520 arrayUnshift(forwardIds, addCheckpointImpl());

Callers 2

goBackwardImplFunction · 0.70
addCheckpointFunction · 0.70

Calls 4

isUndefinedFunction · 0.70
mapSetFunction · 0.70
setCheckpointFunction · 0.70
mapNewFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…