We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
在使用useRequest,并且使用了debounceInterval,会报上述错误 查看源代码 是 p.Date.now 报错,应该是 ahook的问题,我单独使用ahook里的防抖和节流函数也会报这个错误
The text was updated successfully, but these errors were encountered:
可以提供一下代码片段嘛? 目前在官网示例中是有debounceInterval的示例的。
Sorry, something went wrong.
=。- lodash.debounce的锅。在小程序中拿不到global导致self.Date.now()报错了。晚上发一个修复版本修复一下这个问题。
lodash.debounce
global
self.Date.now()
https://github.com/lodash/lodash/blob/master/.internal/root.js#L11
=。- lodash.debounce的锅。在小程序中拿不到global导致self.Date.now()报错了。晚上发一个修复版本修复一下这个问题。 https://github.com/lodash/lodash/blob/master/.internal/root.js#L11
ahooks 里的useDebounce 和 useThrottle 也都有这个问题 不知道之后会不会在taro-hooks 里加这两个hook
=。- lodash.debounce的锅。在小程序中拿不到global导致self.Date.now()报错了。晚上发一个修复版本修复一下这个问题。 https://github.com/lodash/lodash/blob/master/.internal/root.js#L11 ahooks 里的useDebounce 和 useThrottle 也都有这个问题 不知道之后会不会在taro-hooks 里加这两个hook
后面会开启2.0的RFCS. 可以在里面写一下期望有的hooks. 按照顺序会慢慢的都更新进来。但是和环境无关的hooks基本不会重复造轮子。
fixed in v1.5.1
innocces
No branches or pull requests
使用useRequest 时,在小程序里,会报Cannot read property 'now' of undefined 的错误
复现步骤
在使用useRequest,并且使用了debounceInterval,会报上述错误
查看源代码 是 p.Date.now 报错,应该是 ahook的问题,我单独使用ahook里的防抖和节流函数也会报这个错误
The text was updated successfully, but these errors were encountered: