Deployment MERN Stack Error

Hello netlify community, I’m new to netlify and today I’m trying to deploy my application and I keep on getting this error code

Failed to load module script: Expected a JavaScript module script but the server responded with a MIME type of “application/octet-stream”. Strict MIME type checking is enforced for module scripts per HTML spec.

I attached my github and deployed link below with the last log. Please review it thank you

netlify
GitHub

@Kimichi It looks like you haven’t set your Build Configuration and thus you aren’t building your project and are accidentally deploying your source code.

The Build Configuration isn’t set automatically, you need to set the values as appropriate depending on what you want Netlify to run and deploy.

Proof of deployed source files:
https://main–jstudiov2.netlify.app/README.md
https://main–jstudiov2.netlify.app/vite.config.js

It’s hard to tell since you didn’t supply your full build log, and you have a /dist/ folder in your repository, but it’s possible you are running your build and just deploying the wrong folder too.

Based on your monorepo repository my guess is that you want something like:
Base directory = client
Build command = CI= npm run build
Publish directory = dist

1 Like