Skip to content
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

fix: Update useQueryStates state cache when syncing from useSearchParams #776

Merged
merged 3 commits into from
Nov 19, 2024

Conversation

franky47
Copy link
Member

@franky47 franky47 commented Nov 19, 2024

This fixes an issue where <Link> navigation (or external updates of the URL) kept an internal stale state ref and reused it when updating other search params.

Closes #763, #774.

Copy link

vercel bot commented Nov 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
nuqs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 19, 2024 10:29am

@franky47 franky47 added this to the 🪵 Backlog milestone Nov 19, 2024
Copy link

pkg-pr-new bot commented Nov 19, 2024

Open in Stackblitz

pnpm add https://pkg.pr.new/nuqs@776

commit: 6249b6c

@47ng 47ng deleted a comment from pkg-pr-new bot Nov 19, 2024
@franky47 franky47 marked this pull request as ready for review November 19, 2024 10:30
@franky47 franky47 linked an issue Nov 19, 2024 that may be closed by this pull request
@franky47 franky47 merged commit a504e0e into next Nov 19, 2024
27 checks passed
@franky47 franky47 deleted the fix/774 branch November 19, 2024 19:35
Copy link

🎉 This PR is included in version 2.2.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

@franky47 franky47 removed this from the 🚀 Shipping next milestone Nov 20, 2024
@franky47 franky47 mentioned this pull request Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Old Query Param Value Gets Rehydrated After Navigation useQueryStates updater function has an "old" value
1 participant