I have been struggling a lot to tackle this problem but still I cannot find the right answer.
When I try to deploy my react app made by vite to github pages, there is a blank page. But locally, it works perfect.
This is the page I have deployed.
And this is my github repository.
I've already checked several options:
- my base is set to
base: "{soheum.github.io}"
invite.config.ts
file - tried deploying with
vite.config.ts
andvite.config.js
- in my
package.json
I have included"homepage": "https://soheum.github.io/soheum.github.io"
And there is this error in my console log:
Failed to load module script: Expected a JavaScript module script but the server responded with a MIME type of "text/jsx". Strict MIME type checking is enforced for module scripts per HTML spec.
Are there any ways to fix this..?
Thanks a lot!