Error deploying React Native app: Build script returned non-zero exit code: 2

Hello. I am trying to deploy my React Native app and have the current deploy settings to ‘CI= npm build’. However, I’m still coming up with this error that reads:
6:43:14 PM: Failed during stage ‘building site’: Build script returned non-zero exit code: 2 (Search results for '"non-zero exit code: 2"' - Netlify Support Forums)

Can someone please help me fix this? This is the deployment log:
https://app.netlify.com/sites/lively-chimera-76b60a/deploys/634c426d83d30f2840e203e5

This is the problem:

https://app.netlify.com/sites/lively-chimera-76b60a/deploys/634c426d83d30f2840e203e5#L154

It appears to be a problem with your code, not Netlify.

Thank you. I fixed my package.json file and added a .babelrc file which fixed the issue with the Babel 7 update, but it still reads “Command failed with exit code 1: CI= npm run build (Search results for '"non-zero exit code: 1"' - Netlify Support Forums)”

New deployment log: Netlify App

Another code error: Netlify App

You’re reading .thisCompilation of something that’s not defined.