Using 7.0.0-rc.15
Describe the bug
Originally created a conversation on Spectrum but I believe since this is a bug it might be better suited to be on Github.
I'm running into a bug when trying to use useAsyncDebounce:
index.es.js:286 Uncaught (in promise) TypeError: fn is not a function
at _callee$ (index.es.js:286)
at tryCatch (runtime.js:45)
at Generator.invoke [as _invoke] (runtime.js:271)
at Generator.prototype.<computed> [as next] (runtime.js:97)
at tryCatch (runtime.js:45)
at invoke (runtime.js:135)
at runtime.js:170
at new Promise (<anonymous>)
at callInvokeWithMethodAndArg (runtime.js:169)
at AsyncIterator.enqueue [as _invoke] (runtime.js:192)
What I'm trying to accomplish:
To Reproduce
For full steps on my exact use case and bug discovery (including my actual code) please visit the spectrum post. Will leave out my full code from the bug here.
I created a Sandbox for a simple recreation. The sandbox uses the pagination controlled example as it's base and simply adds the useAsyncDebounce as described here
Expected behavior
I expect to not get an error and have a usable debounced function which will prevent pageIndex state being reset to 0 twice in order to avoid 2 consecutive data fetches.
Screenshots

Desktop (please complete the following information):
I'll look into this ASAP. Thanks!
@tannerlinsley i was able to provide a hotfix in this pr https://github.com/tannerlinsley/react-table/pull/1796
There are actually deeper problems with this function beyond what you fixed. I'll be shipping a new useAsyncDebounce function to address both the issues you brought up and the other ones I just found. :)
any updates, @tannerlinsley?
This will be fixed in the next release.
This will be fixed in the next release.
Ah, I probably shoulda been more clear in my question. Was wondering what's the ETA on the next release? Just want to give my team notice as to around when to expect a fix. Thanks for your hard work!
I am running into the same problem.
Thank you for submitting the report @nicholaai and working on a new release @tannerlinsley.
I will wait for the new release before using useAsyncDebounce
Fixed in master, slated for release. Thanks!
Most helpful comment
This will be fixed in the next release.