Selective Data Fetching and Loading States #10064
-
Beta Was this translation helpful? Give feedback.
Answered by
sergiodxa
Oct 5, 2024
Replies: 1 comment 7 replies
-
A route is a single unit so it's not possible to only revalidate part of a route loader, but you can split a route on two routes with different loaders essentially creating two units that can run independently of each other. In your case you could have route for the chart and another for the list, then you can use shouldRevalidate on the list route to avoid it, nest one inside the other and you will have a single UI built using two routes. |
Beta Was this translation helpful? Give feedback.
7 replies
Answer selected by
RabeeAbuBaker
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A route is a single unit so it's not possible to only revalidate part of a route loader, but you can split a route on two routes with different loaders essentially creating two units that can run independently of each other.
In your case you could have route for the chart and another for the list, then you can use shouldRevalidate on the list route to avoid it, nest one inside the other and you will have a single UI built using two routes.