Dynamic routes with params using data defetching fail on subsequent navigations #169
Replies: 1 comment 3 replies
-
You had a few issues:
A few extra notes: you don't need to export the loader from App. In fact, App.vue is the only component that cannot use a loader as it mounts before the navigation starts (unless you await for the first navigation before calling Here you have a working example: https://stackblitz.com/edit/vitejs-vite-pmdkkm?file=src%2FApp.vue,src%2Floader.ts,src%2Fpages%2Ftest%2F[slug]%2Findex.vue,src%2Fmain.ts (not sure how long it will stay up) |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Using following page structure
route/[slug]
and using data fetching, changing between slugsRangeError: Maximum call stack size exceeded
is thrown.The whole issue is bit hard to explain, so here is a reproduction
Screen.Recording.2023-05-22.at.13.16.17.mov
On my local setup if I on initial load/refresh everything is fine, only subsequent navigations result in failure.
Beta Was this translation helpful? Give feedback.
All reactions