T
TanStack16mo ago
solid-orange

useFocusNotifyOnChangeProps hook notifyOnChangeProps type issue

Hello! I use v5.17.7 React-query with react native. I want to use the useFocusNotifyOnChangeProps hook like the docs said. ( https://tanstack.com/query/latest/docs/framework/react/react-native#disable-re-renders-on-out-of-focus-screens ) But I got type issue and dont know how to fix that. Do you have any idea how to fix that? Thank you
No description
4 Replies
ratty-blush
ratty-blush16mo ago
please show a typescript playground
ratty-blush
ratty-blush16mo ago
thx. we haven an open PR to fix this: https://github.com/TanStack/query/pull/7441
GitHub
fix(query-core): allow function value of notifyOnChangeProps quer...
undefined is a valid return value for the function value of notifyOnChangeProps. See linked issue for more details. Fixes #7426.
solid-orange
solid-orangeOP16mo ago
Thank you ! :reactcharts:

Did you find this page helpful?