While attempting to host my webpage with a three.js background, I encountered an issue where everything loads properly when hosted locally, but nothing loads when pushed to GitHub pages - only the HTML is visible.
I am utilizing Vite to package my code and Gh-pages to deploy the 'dist' folder to the hosted branch. I have attempted to adjust the URLs of all images and assets to '/image' and store them in a public folder within the root directory following Vite's recommendations. After running $ npm run build, and $ npm run preview, everything appears to be working fine. However, after running npm run deploy (I included a deploy script in package.json: deploy: 'gh-pages -d dist'), hosting the gh-pages branch on GitHub pages only displays the HTML content, and the console displays multiple 404 errors for files not found.
If it wasn't clear already, the code being hosted can be found on the gh-pages branch.