Skip to content
← Back to Community
ReactJS - Couldn't reach repl
Profile icon
mido7778

When I run my ReactJS repl, the section that displays the HTML result say


Hmmmm.... We Couldn't Reach Your Repl Make sure your repl has a port open and is ready to receive HTTP traffic.

why??

Answered by Coder100 [earned 5 cycles]
View Answer
Voters
Profile icon
TwinCities199
Profile icon
mido7778
Comments
hotnewtop
Profile icon
Coder100

You just have a small problem.
You must have accidentally deleted serviceWorker.js or something, because that usually comes with the repl.

No worries, serviceWorkers only speed up initial load times, it's not super big of a deal if it doesn't exist, many websites don't.

Remove this line:

image

src/index.js if you will.

Profile icon
mido7778

@Coder100

It's work. Thank's so much.

Profile icon
Coder100
Profile icon
SameeraMurthy

Solution

You need to wait a few moments for React to start up.
Wait till it says "Compiled Successfully!" in the console.
Don't forget to press the refresh button after you do this.

In src/index.js, on line 5, delete

import * as serviceWorker from './serviceWorker';

This is because the file ./serviceWorker doesn't exist.

Hope this helps.

Profile icon
mido7778

@SameeraMurthy

Thanks dude.