Next.js Discord

Discord Forum

Loading page with search query

Answered
Manas posted this in #help-forum
Open in Discord
So i have a word/ page with a search param, i.e. word?word=xyz now in here, whenever i navigate from word=xyz to word=abc, loading page doesn't show up... and it just seems as if the page is stuck until the fetch for abc completes and then the page renders over the current.

I want the loading page to be shown even when i'm navigating in between the same page with different search query
Answered by Manas
Silly me, the issue was related to how the next.js Link component is set to prefetch by default,

Changing List component to an <a> tag solved the issue, but one can even explicitly pass
<... prefetch={false}>
to disable it
View full answer

5 Replies

Hmm
Asian black bear
Please don't bump your post within minutes using low-effort messages.
Okay
sorry for that.
Silly me, the issue was related to how the next.js Link component is set to prefetch by default,

Changing List component to an <a> tag solved the issue, but one can even explicitly pass
<... prefetch={false}>
to disable it
Answer