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

Link not working in production #9785

Closed
flizana opened this issue Dec 19, 2019 · 5 comments
Closed

Link not working in production #9785

flizana opened this issue Dec 19, 2019 · 5 comments

Comments

@flizana
Copy link

flizana commented Dec 19, 2019

I have various Link in my application but when deployed in production they stop working. The code is as follows:

<Link href="/register">
  <a>Register</a>
</Link>

When navigating in development they work fine. When I deploy to production the link takes forever to load the next page. If I write the URL in the address bar it loads fine. When I click on the Link it just hangs, and never loads the page.

Production environment is:

Ubuntu 18.04
Node.js custom server (Express) behind Nginx.

@ijjk
Copy link
Member

ijjk commented Dec 19, 2019

Hi, please follow the issue template.

This sounds like a duplicate of vercel/next-plugins#282. We are looking into fixing this and opened a RFC here. If you are using global CSS only you can test out the experimental support by adding module.exports = { experimental: { css: true } } to your next.config.js

I'm going to close this as this is most likely the issue and it doesn't follow the issue template

@ijjk ijjk closed this as completed Dec 19, 2019
@YoLoADR
Copy link

YoLoADR commented Feb 20, 2021

I have various Link in my application but when deployed in production they stop working. The code is as follows:

<Link href="/register">
  <a>Register</a>
</Link>

When navigating in development they work fine. When I deploy to production the link takes forever to load the next page. If I write the URL in the address bar it loads fine. When I click on the Link it just hangs, and never loads the page.

Production environment is:

Ubuntu 18.04
Node.js custom server (Express) behind Nginx.

Do you find the solution ? because I have the same issue

@amiguet3
Copy link

Use passHref

@RacketyWater7
Copy link

RacketyWater7 commented Dec 17, 2021

Use passHref

I did. But still it doesn't work sometimes in production. I click the Link and its as if nothing happens; as if the Link did not hear the command. Then I have to refresh the page multiple times and then it works. So sometime it works and sometimes don't.

@balazsorban44
Copy link
Member

This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@vercel vercel locked as resolved and limited conversation to collaborators Jan 27, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants