React development server disconnected problem

Are you an “IT Crowd” fan too?

1 Like
  1. If you installed it with something like create-react-app ProblemForReactJS, then that sounds like the old way. I would uninstall CRA and use the method described here.
  1. If Chrome is working, that may be an indication that we’re on the right track.
1 Like

I never pass up a chance to slip that in there. :wink:

1 Like

Okay, thanks, ı gonna try.

And you don’t have to give up your old projects - you can just copy the src folder from the old project into the new, reinstall your dependencies, and it should work.

This is not working.

Well, did you say it worked on Chrome? In either case, my next step would be to make sure the browsers are updated.

Yes, i Said but ı dont use Google Chrome. it’s not working the other browserse (edge, firefox) that’s mean literally not working also my browser is currently.

Yes, i Said but ı dont use Google Chrome.

I don’t see where you said that. I see:

Excuse me. I’m confused. I downloaded the CRA from the old way also it’s working at the chrome.

If you have a browser that is working, why not use that? Chrome is a popular and dependable choice. I might stay away from Edge as my default dev browser. FF should be OK - I’m not sure what the problem is there.

In any case, you have an issue here. As near as I can tell, it is one of a few possibilities.

  1. Your setup isn’t making the server properly.
  2. Your browser isn’t talking to the server correctly.
  3. You’re doing something that is interfering.

If we ignore the last one, then we’re left with making sure your project gets set up properly or making sure you have the most current browser. That is what I’m trying to get you to verify but I feel like I’m pulling teeth here so I guess I can’t help you.

My only advice is to make sure that everything is up to date and start scouring google and stack overflow for those error codes.

webpack-dev-server (WDS) is the officially maintained development server running in-memory, meaning the bundle contents aren’t written out to files but stored in memory. The distinction is vital when trying to debug code and styles.

i have the same problem but it doesn’t work on chrome too
and that happens to me just sometimes and t take too long to go back normal

So same thing happening to me, i install react using CRA -g
when i run it local server npm start
after refreshing the page it shows
(The development server has disconnected.
Refresh the page if necessary.)

1 Like

I’m having the same problem but I set up my CRA using `npx create-react-app’.

basically, the problem i was facing was I was only working on idex.js that why I face the problem

I followed this tutorial and I get “The development server has disconnected.
Refresh the page if necessary. webpackHotDevClient.js:76
[HMR] Waiting for update signal from WDS…” only in the Firefox’s console. In Chrome it works as intended.

GET, PUT, DELETE requests work fine in Firefox, but POST works only once. I have to restart npm for POST to work again in Firefox through front-end. Back-end always works fine.

I’m touching React for the first time.

re: Firefox disconnecting

I was also having this problem, and tried a couple other things not listed here (including installing Firefox Dev Ed. which I had been meaning to do anyway), and I noticed that this only happens to me after I’ve manually hit the refresh button (i.e. F5, cmd-R).

I do it pretty reflexively, but it explains (for me anyway) why sometimes the dev server just wouldn’t stay connected. Its on my to-do list to figure out if there’s a way to relaunch the page from the dev server console without restarting the whole thing rather than the browser refresh, because after all sometimes I make a mistake that breaks the page reloading.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.