react-tooltip icon indicating copy to clipboard operation
react-tooltip copied to clipboard

Tooltip is not shown once it is deployed to Vercel

Open tech02223 opened this issue 1 year ago • 6 comments

Hello. Currently I'm working on Next.js, and built my website. I used react-tooltip module to display a tooltip, and it works well on localhost. But I noticed that tooltip is not shown after the website is deployed. I'm not sure what I did incorrectly.

tech02223 avatar Aug 16 '24 20:08 tech02223

We have two sections on our troubleshooting page about possible issues with Next.js:

  1. Next.js TypeError: f is not a function
  2. Next.js "use client" error

If your issue does not relate to either of these situations, please try to give us some more information on what's exactly happening there.

gabrieljablonski avatar Aug 16 '24 21:08 gabrieljablonski

I don't think my issue is not related to above issues. It works correctly on localhost. I can see the tooltips. But I cannot see those tooltips if I deploy my website to Vercel. It is hosted in static mode.

tech02223 avatar Aug 16 '24 21:08 tech02223

Is your deployed project publicly available? If yes, please share so I can take a look.

If not, you'll need to do some investigation and see if you can find out anything to help us figure out the issue.

Best I can think of right now is to check the browser console in production and see if anything shows up there. Also check the console on localhost to see if there's anything that might get suppressed on production.

gabrieljablonski avatar Aug 16 '24 21:08 gabrieljablonski

@tech02223 is the tooltip working on your project on both commands on your localhost? yarn dev, yarn build && yarn start

I'm asking because of the behavior of Next.js + React on development mode is different from production build.

danielbarion avatar Aug 16 '24 22:08 danielbarion

I have same problem. It works well wher yarn dev but not working after yarn build Uncaught (in promise) TypeError: w is not a function

berejznoy avatar Sep 23 '24 10:09 berejznoy

@berejznoy @tech02223 can you guys please create a reproducible example with a fresh Next.js project? I'll take a look when you guys share it

danielbarion avatar Oct 18 '24 13:10 danielbarion

I had the same problem. Tried disabling webpack optimization minimizing in next.config.js to see the error, but that actually fixed the issue. What solved it was upgrading next package to 13.3.0 as shown in the first link commented by @gabrieljablonski.

Emroni avatar Oct 30 '24 16:10 Emroni