-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
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
Removing unnecessary calls to mutateStreamData in useChat React hook #2951
base: main
Are you sure you want to change the base?
Removing unnecessary calls to mutateStreamData in useChat React hook #2951
Conversation
Hey @tonyfarney meant to come back to this - the issue is legit, but I need to verify this fix actually works in different settings, e.g.. when something is already non-empty or when there are non-changes for non-empty data. |
Looking the code, the only situation data is not an empty array when passed to update([...previousMessages, ...merged], [...data]); // make a copy of the data array I think it's possible the situation of calling the |
Hey @lgrammel! Do you think my changes will be accepted and merged? |
This fixes #2950