Hello, I developed a react JS website using Vite and appwrite for the backend which is running perfectly on localhost but when I am trying to host on Netlify it gives me the following error
“main.jsx:1 Failed to load module script: Expected a JavaScript module script but the server responded with a MIME type of “text/plain”. Strict MIME type checking is enforced for module scripts per HTML spec.”
I have tried to clear browser cache, mobile, laptop, different networks, different browsers, etc but doesn’t work at all.
I bought a custom domain on Hostinger and changed the required settings to use Netlify DNS which showed successful on Netlify, but now is am getting this annoying error constantly. When I am checking the content type in the network it shows a content type of text/plain. Please help me resolve this error as this is for production.
Website Link:- rishi-bhumi.com
Update:- The website worked perfectly after writing this post but for no reason automatically the problem started to occur again.