I am working on a small react app/website as part of my learning practice. I tried to host it on github pages. I followed the below video procedure. The app is working in local but after hosting on gihub pages its giving blank screen with no console errors.
Video: https://www.youtube.com/watch?v=7wzuievFjrk
Repo: https://github.com/sainath27/project_social_app
Build branch: gh-pages
Website: https://sainath27.github.io/project_social_app/
it is expected to show login kinda webpage asking for name & password.
2
Answers
you can not run the react project directly from gh pages, you have to set the build of the project in your repo.
To build Run
npm run build
and push that build folder
also You can refer this portion of video
see this Portion of the video https://youtu.be/7wzuievFjrk?si=tyNoZIWQ-_-0Y4w9&t=184
Try to add
to package.json