Replies: 1 comment
-
(default)shouldReload looks like a nice idea. |
Beta Was this translation helpful? Give feedback.
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.
-
🐞 What happens today
#hash
results inmatch.cause === "stay"
.shouldReload
, the loader runs again even though the route,pathname
, andsearch
haven’t changed.loaderDeps
– callback/object that controls cache keys (not whether the loader runs).shouldReload
– per-route function that decides if the loader executes.defaultShouldReload
option.🔧 Work-around we’re using
🙈 Drawbacks
prevLoc
ourselves; can reset under HMR, parallel bundles, SSR.🌱 Ideas for the future — not implemented
Router-wide opt-in
Previous context in
shouldReload
Simple flag
ignoreHash: true
at either router or route level.❓ Questions for maintainers & community
defaultShouldReload
/ignoreHash
) be welcome?shouldReload
?Beta Was this translation helpful? Give feedback.
All reactions