Failed to load module script: Expected a JavaScript module script but the server responded with a MIME type of "text/html". Strict MIME type checking is enforced for module scripts per HTML spec

Thank you! It helped a lot. I changed the “base” property in the vite.config.js to “/” and it seems to work properly now!

export default defineConfig({
plugins: [react()],
base: “/”
})