MCPcopy Index your code
hub / github.com/pmndrs/react-spring / flush

Function flush

packages/shared/src/helpers.ts:79–85  ·  view source on GitHub ↗
(queue: any, iterator: any)

Source from the content-addressed store, hash-verified

77): void
78export function flush<T>(queue: Set<T>, iterator: (value: T) => void): void
79export function flush(queue: any, iterator: any) {
80 if (queue.size) {
81 const items = Array.from(queue)
82 queue.clear()
83 each(items, iterator)
84 }
85}
86
87/** Call every function in the queue with the same arguments. */
88export const flushCalls = <T extends AnyFn>(

Callers 3

_onFrameMethod · 0.90
stopAsyncFunction · 0.90
flushCallsFunction · 0.70

Calls 1

eachFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…