Reputation: 1
I'm new to coding and built a couple websites using react; however, once deployed onto github pages the readme is what the browser is showing. It either shows the readme because its at the root or once moved to the root it still cannot find the index.html file because it looked in the public folder.
Upvotes: 0
Views: 18
Reputation: 2254
GitHub isn't a normal web host from which you can host a website. It is meant for versioning and sharing source code, including of web pages but of other languages too. Because of this, viewing a repository on GitHub defaults to showing the README.md file, which is what most other developers would want to know.
There are a few ways you can get GitHub to do what you're describing, i.e. serving raw files, including a service they offer called GitHub Pages but it's probably not as fully featured as what you're looking for. Instead, find a web host (just google it, there's thousands) and set up a cheap account. Shouldn't cost you more than a couple dozen USD a year.
Upvotes: 0