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
@reskript/no-useless-memo-hooks
重现 Case:
const getInitialValues = useCallback( () => template, [template] );
@reskript/no-useless-memo-hooks 提示 Hook useCallback's should be removed
Hook useCallback's should be removed
但实际上,我希望仅当 template 的值发生变更时使用新的 callback,而当 template 的值没有变化时不更新 callback 的引用。在这种情况下,useCallback 是需要的。
template
callback
useCallback
The text was updated successfully, but these errors were encountered:
No branches or pull requests
重现 Case:
@reskript/no-useless-memo-hooks
提示Hook useCallback's should be removed
但实际上,我希望仅当
template
的值发生变更时使用新的callback
,而当template
的值没有变化时不更新callback
的引用。在这种情况下,useCallback
是需要的。The text was updated successfully, but these errors were encountered: