top | item 44824428

(no title)

joeframbach | 6 months ago

That doesn't sound correct. An async function ought to return a _new_ Promise on each invocation, and each of those returned Promises are independent. Are you conflating memoization? Memoized functions will have these problems with denouncing, but not your standard async function.

discuss

order

ricardobeat|6 months ago

If I understand it correctly, they're saying the debounce function itself usually implements memoization in a way that will return you stale promises.