Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't fetch! #16

Open
gitgetgotgotten opened this issue Dec 6, 2021 · 1 comment
Open

Doesn't fetch! #16

gitgetgotgotten opened this issue Dec 6, 2021 · 1 comment

Comments

@gitgetgotgotten
Copy link

When I open the localhost:3000 in the browser, the next.js is working and I can navigate to different pages, but the problem is that it doesn't prefetch the other pages.

My cache is disabled.

In the /components/layouts.js file, I even added this line below to check if it works statically:

router.prefetch('/index.js')
router.prefetch('/example.js')
router.prefetch('/about.js')
router.prefetch('/media.js')

No luck.

@sainisagar310
Copy link

@gitgetgotgotten The prefetch is a production-only feature. Next.js doesn't prefetch pages in development.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants