MCPcopy Create free account
hub / github.com/chakra-ui/panda / updateKeyUsage

Method updateKeyUsage

packages/shared/src/cache-map.ts:40–46  ·  view source on GitHub ↗
(key: K)

Source from the content-addressed store, hash-verified

38 }
39
40 private updateKeyUsage(key: K) {
41 const index = this.keysInUse.indexOf(key)
42 if (index !== -1) {
43 this.keysInUse.splice(index, 1)
44 }
45 this.keysInUse.push(key)
46 }
47
48 private evictLeastRecentlyUsed() {
49 const keyToEvict = this.keysInUse.shift()

Callers 4

getMethod · 0.95
setMethod · 0.95
getOrInsertMethod · 0.95
getOrInsertComputedMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected