javascripthtmlreactjsserverweb-hosting

MIME type checking failure when deploying the React App on the server


I am deploying my React app on a public server but when I open it I just get the blank page.

In order to deploy the app I did:

1) run "npm run build" to minify the code and putting into a build folder
2) replaced the local URL in the new index.html file with the correct server ones.

still, when trying to open the website in the console I get these errors.

error image

Any ideas?


Solution

  • I solved the problem simply correcting the url.

    since I was already accessing the "public" folder thanks to the "./" typing in the beginning of the url, there was no need to type "./public".

    Thank you anyway.