MCPcopy Index your code
hub / github.com/TanStack/db / forEach

Method forEach

packages/db/src/SortedMap.ts:208–214  ·  view source on GitHub ↗

* Executes a callback function for each key-value pair in the map in sorted order * * @param callbackfn - Function to execute for each entry

(
    callbackfn: (value: TValue, key: TKey, map: Map<TKey, TValue>) => void,
  )

Source from the content-addressed store, hash-verified

206 * @param callbackfn - Function to execute for each entry
207 */
208 forEach(
209 callbackfn: (value: TValue, key: TKey, map: Map<TKey, TValue>) => void,
210 ): void {
211 for (const key of this.sortedKeys) {
212 callbackfn(this.map.get(key)!, key, this.map)
213 }
214 }
215}

Calls 1

getMethod · 0.45

Tested by 9

triggerAllTimeoutsFunction · 0.36
triggerStorageEventMethod · 0.36
createBasicTestsFunction · 0.36
testJoinTypeFunction · 0.36
createJoinTestsFunction · 0.36
createSubqueryTestsFunction · 0.36
createJoinSubqueryTestsFunction · 0.36
createOrderByBugTestsFunction · 0.36