Monday, June 3, 2024
 Popular · Latest · Hot · Upcoming
56
rated 0 times [  59] [ 3]  / answers: 1 / hits: 17392  / 5 Years ago, fri, february 8, 2019, 12:00:00

I'm suddenly having issues with production versions of my react apps. They work fine in development, however when I build them, I get a console error:



/static/css/main.f6418f8a.chunk.css:1 Failed to load resource:




net::ERR_FILE_NOT_FOUND



1.13eeb203.chunk.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND



main.1e6014ca.chunk.js:1 Failed to load resource:
net::ERR_FILE_NOT_FOUND



/favicon.ico:1 Failed to load resource: net::ERR_FILE_NOT_FOUND




This error was received after the following commands:



create-react-app whatiswrong



npm run build



Then open the index.html in my browser like I would for any other react apps I've built.


More From » reactjs

 Answers
38

You need to add "homepage": "./" to your package.json.


From:
https://github.com/facebook/create-react-app/issues/6275#issuecomment-457813277


[#52635] Sunday, February 3, 2019, 5 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
lizet

Total Points: 479
Total Questions: 96
Total Answers: 113

Location: Mexico
Member since Sun, Jul 25, 2021
3 Years ago
;