Reputation: 63
Tried to run npm start
on a project I hadn't looked at in a couple weeks and when I did it opens up localhost:3000/myname/partofmyprojectname
instead of just localhost:3000/
When I go to localhost:3000/
there's an error in my terminal
Really confusing because it worked last time I tried it and I didn't change anything I don't think.
Upvotes: 2
Views: 973
Reputation: 63
As I was making this question I found the solution from this post:
In my package.json, "homepage"
's value was the path to the readme in the github repo: "https://github.com/myname/my-app-frontend#readme"
(don't know how that happened). I just changed that to '/'
.
I'm thinking maybe my version of react-scripts updated and npm start
was deferring to the homepage key in the package.json
but not totally sure.
Upvotes: 2