You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I opened the ticket here and not in the documentation repo, because this is about the upcoming version, and it seems there might not be clarity on what should be the expected behavior. Forgive me if it still was supposed to go on the other repo.
The text was updated successfully, but these errors were encountered:
updateFn is not required, but if you use it it will work more like usereducer hook. then you have to make the function for updateFn and then dispatch it to show optimistic value.
Summary
Main docs show that useOptimistic has a required second parameter updateFn.
The RC blog post does not, though.
The current version, 19.0.0-rc-e948a5ac-20240807, seems to work without the second parameter (example).
I opened the ticket here and not in the documentation repo, because this is about the upcoming version, and it seems there might not be clarity on what should be the expected behavior. Forgive me if it still was supposed to go on the other repo.
The text was updated successfully, but these errors were encountered: