I have a react app which is working perfectly fine on windows but it is not working on my live ubuntu server. I get the following console msgs in chrome when I try to visit the page.
I am not able to figure out what is the issue here. I re-run npm install and checked code. Code is running fine on windowns but not on ubuntu server.
I get the following error in ubuntu command prompt:
It was the problem with the file "bin - Copy.png"
script was looking for "bin - copy.png" whereas the file name was "bin - Copy.png"
I edited the file name and everything worked well.
Related
I'm using VSCode with WSL. With the Remote WSL extension I'm opening my project in VSCode. I'm running my project (it's a react project) in WSL. First I can connect to my application on localhost:3000 but after a while my browser says that it couldn't connect to it. My project is running fine without errors. I've tried it with Chrome, Edge and Firefox (with and without extensions). Same thing. After a while it loses connection. If I run the project on my local windows it works fine. It used to work with WSL too just a few days before.
Brower connection error
My project running without issues
I've tried updating all of the WSL packages and reinstalling all of my VSCode extensions but it didn't help. Any idea what's causing this issue and how to solve it?
Since this morning I can't launch any React JS Project in my dev server.
I explain. When I launch npm start command, all works fine, no any error message, all works as usual, it opens me a tab in my browser, but it loads forever and I just have a blank page loading.
For information, I works on a Windows System, with WSL Debian distro.
I tried to open it with http://localhost:3000, http://127.0.0.1:3000 and with my local IP adress (that's an exemple) http://192.168.0.1:3000, I also changed browser (Chrome / Edge ), and every thing is the same.
After that I launch with npm start an Express project -> it works like a charm.
I also tried with a Symfony project, here with the PHP dev server php -S 0.0.0.0:8000 -t public and same as Express, it displays normaly in my browser.
So I'm pretty sure there is something with React, but that's on all mys REact projects, not with one particulary, and again, there is no error in my console, output is like everyday, so that's very strange and I really don't get it!
If someone has any idea 🙏
image describe my problem
Hi Guys, I had this problem when I launched my React project with Live Server extension. It showed the project's folders instead of running the application. I've removed Live Server extension and reinstalled it but I've got the same issue. When I run it from the terminal with "npm run start" command it works well, please guide me because I read and test solutions being in this link link but it doesn't work.
Try your localhost:3000 or npm start
This is because your React code needs to be compiled. You can run a live server using React with
npm start
I am brand new to react. I installed it on my work computer and the first compile worked fine and it showed on the local host just fine and had the cool react logo spinning. I decided to install it on my home PC and run it, compiles fine in the terminal but the webpage that shows up is blank. I haven't changed anything in the files.
Thanks in advance for the help!
Edit: OS Windows, Node.js Version 13.8.0, npm version 6.13.6, npx 6.13.6, Browser Google Chrome
I am currently pretty lost where to start searching for the error that I am facing. The same AngularJS project that my colleagues have been working on for quite a while on Macs cannot be compiled correctly on my Windows machine. No idea if windows and mac has anything to do with the error but just in case I am adding this information.
I've checked out the project with SourceTree and opend it with WebStorm.
First npm install then gulp dev in the terminal of WebStorm and my angularJs-project is beeing compiled without any errors. When then the browser windows with //localhost is beeing opened, the page shows shortly the loading anymation and then stays blank.
In the attached screenshot you can see the output of the console. Any ideas?
AngularJS Version: 1.7.2
NPM Version: 5.6.0
Gulp:
CLI version 3.9.1
Local version 3.9.1
What could make the difference that the project is running perfectly on other machines but not on mine?
[Edit]:
I have now reanimated my old macbook, checked out the exact same project with source tree, installed webstorm, ran npm install, then doing this to set up gulp and then running gulp dev: The App runs just fine.
On my Windows Laptop I've started all over, deinstalled WebStorm, deinstalled node.js and did the whole set up as described above. Only difference that I need to install node.js manually on Windows to use npm.... same error as described before.