MCPcopy
hub / github.com/witheve/Eve / replaceAll

Function replaceAll

src/codemirror.js:13954–13962  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

13952 var done = false;
13953 var lastPos = searchCursor.from();
13954 function replaceAll() {
13955 cm.operation(function() {
13956 while (!done) {
13957 replace();
13958 next();
13959 }
13960 stop();
13961 });
13962 }
13963 function replace() {
13964 var text = cm.getRange(searchCursor.from(), searchCursor.to());
13965 var newText = text.replace(query, replaceWith);

Callers 1

doReplaceFunction · 0.85

Calls 4

replaceFunction · 0.85
stopFunction · 0.85
operationMethod · 0.80
nextFunction · 0.70

Tested by

no test coverage detected