Repository navigation
Replies: 2 comments 3 replies
1 reply
|
The difference is that execute is a private method and flush is public. This is true for all versions of the batcher. You weren't even able to call execute in your own code, right? |
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Look at https://github.com/TanStack/pacer/blob/main/packages/pacer-lite/src/lite-batcher.ts, the only difference is that flush clears the timeout before executing. With that in mind, what's the reason someone would want to execute the batch without clearing the timeout? Is that just asking for weird behavior?
Asking as from https://tanstack.com/pacer/latest/docs/guides/batching#batcher-methods - it wasn't very clear to me ("Manually process the current batch" vs "Flush pending batch immediately").
All reactions