question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Metro and the client are out of sync. Reload to reconnect.

See original GitHub issue

Every once in a few saves when using a new tailwind class I get this error: Metro and the client are out of sync. Reload to reconnect.

If I’m using tailwind classes that I’ve already used (they currently exist in tailwind.css), I never get the error.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
jonsampcommented, Jan 22, 2022

I ran into this same issue. I attempted to add a custom metro.config.js to my project to add middleware, but I was not able to figure it out. If someone smarter than me wants to help, I think there may be a race condition where metro is watching files so that it can run HMR (fast refresh). But since some files change immediately because of yarn dev:tailwind, my hypothesis is that this causes metro to get out of sync.

Instead of running yarn dev:tailwind, I wonder if it’s possible to run yarn build:tailwind before metro executes HMR? Just an idea.

0reactions
vadimdemedescommented, Jan 31, 2022

Awesome, thanks for the recording!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Disconnected from the Metro server. Reload to reconnect
Using RN with Expo, I've started getting the Disconnected from the Metro server. Reload to reconnect error to appear pretty much every time ......
Read more >
[SDK 45.0.1][expo-dev-client] No reconnect to Metro ... - GitHub
Open developer menu and hit "reload"; App will be blank and white. I am not sure why expo-dev-client can't reconnect to Metro in...
Read more >
Disconnected from the Metro server. Reload to reconnect
Hello, For some time, something is wrong with the metro-bundler/build service, and I'm not able to figure out why I constantly get ...
Read more >
react native metro bundler not starting : Solved Solution
Recently a lot of programmers are having issue on using a react native init application to start an app all because of a...
Read more >
How do I stop Metro Server/Expo from quitting unexpectedly?
This happens to me i usually just click "R" to reload it and it connects without have to stop and start the server...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found