Project page serving from the wrong URL [SOLVED]

When I go to my custom domain http://example.com, nothing appears. The network requests are attempting to fetch the static files from http://example.com/PROJECT_NAME/static/main.js, when they are actually located at http://example.com/static/main.js. 

2 Likes

Solution:

Setting package.json’s “homepage” field to “name.github.io” instead of “name.github.io/project_name”.

Since DNS providers route to name.github.io for all (even multiple) projects, and uses CNAME to identify the project, the static files should be served from name.github.io, not name.github.io/project_name

1 Like

I need an explanation of this. What to edit in the package.json file.