Navigating between pages takes a few seconds
Unanswered
sergiy.eth posted this in #help-forum
I am using App Router and I have a few different settings pages in my app. I have a layout like this
I have a
And i have a
which is just a few skeleton components.
When i click to navigate to a different page, there's a 2-3 second delay before showing the actual content of the page, not rendering the loading screen sometimes. am i doing something wrong? this is hosted on vercel
I have a
layout.tsx in the settings folder with a navigation component that has a few Link components. Each page folder has a page.tsx and it is either a server component or a client component using tanstack query. And i have a
loading.tsx for each one of the pages that looks like thisimport LoadingSettings from '@/components/settings/loading-settings';
export default function LoadingProfile() {
return <LoadingSettings />;
}which is just a few skeleton components.
When i click to navigate to a different page, there's a 2-3 second delay before showing the actual content of the page, not rendering the loading screen sometimes. am i doing something wrong? this is hosted on vercel
"next": "^14.2.5",3 Replies
Is this a proper build or just local development?
proper build. locally i understand some time is needed for the pages to compile but i've tried to
next build + next start locally too and it's the same experienceI believe the DevTools Network tab can give you a direction to look. It shows in quite a bit of detail what is being downloaded and from where, and how long it takes.