Repository navigation
Replies: 1 comment
|
Each filter combination has a different query key. A five-minute |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi everyone,
I'm experiencing an issue where my route's pendingComponent is being triggered every time search parameters change, even when I have cached data available. I'd like the skeleton to only show on the initial load, not on subsequent searches/filters.
My Setup:
When users type in the search input (which updates the search URL param), the pendingComponent skeleton shows every time, creating a jarring experience. I want:
✅ Skeleton on initial page load (first visit)
❌ No skeleton when searching/filtering (should show existing data with a loading indicator)
Maybe i am doing something wrong, what is the better way to handle this case.
Should i use useQuery instead of useSuspenseQuery and handle loading manually or i still can use useSuspenseQuery but i must change something.
Any guidance would be much appreciated! Thanks for the amazing library 🙏
Environment:
@tanstack/react-query: ^5.85.3
@tanstack/react-router: ^1.121.2
All reactions