Blank White Page After Deploying React App #140198
-
Hello, I am having an issue with deploying my Final Project to GitHub Pages. When I load the URL, only a blank white page is displayed. I've added the deploy and build script as instructed as well as a homepage script into the package.json file. I've, also, updated the repository name in the base script inside of the vite.config.js file. I'm not getting any errors within the terminal, but when I inspect the blank page in Edge, I am seeing that there is an error in the console stating that the "./src/main.jsx" file cannot be found. But the file is located in the correct directory. I am also receiving a 404 error within the browser's console. I have provided a link to the repository as well as the hosted page: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
@Tmalone1250 |
Beta Was this translation helpful? Give feedback.
@Tmalone1250
It looks like you are deploying from Main; where your source code is located. You need to run a build of your source code and deploy it from the gh-pages branch.
Vite / Pages deployment guide: https://vitejs.dev/guide/static-deploy