Replies: 2 comments 1 reply
-
We don't add such utils here, but feel free to create a third-party package if you think it's useful. Note that you can use arrow function: export function useSubscribe(proxyObject, callback, notifyInSync) {
useEffect(
() => subscribe(proxyObject, callback, notifyInSync),
[proxyObject, callback, notifyInSync]
)
} |
Beta Was this translation helpful? Give feedback.
0 replies
-
But why? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I think it would be useful to have build in react hooks for subscribe, subscribeKey, etc. Something like
Beta Was this translation helpful? Give feedback.
All reactions