MCPcopy
hub / github.com/facebook/react / scheduleCleanUp

Function scheduleCleanUp

packages/react-cache/src/LRU.js:42–49  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

40 let cleanUpIsScheduled: boolean = false;
41
42 function scheduleCleanUp() {
43 if (cleanUpIsScheduled === false && size > LIMIT) {
44 // The cache size exceeds the limit. Schedule a callback to delete the
45 // least recently used entries.
46 cleanUpIsScheduled = true;
47 scheduleCallback(IdlePriority, cleanUp);
48 }
49 }
50
51 function cleanUp() {
52 cleanUpIsScheduled = false;

Callers 2

accessFunction · 0.85
setLimitFunction · 0.85

Calls 1

scheduleCallbackFunction · 0.50

Tested by

no test coverage detected