Cannot read property of undefined

I tried to deploy from github and my logs are
Running build command ‘npm ci’…
npm ERR! Cannot read property ‘axios’ of undefined

I have “const axios = require(‘axios’)” in my code and it works fine locally, what to do?

Hi,

Sounds like you might not have installed your dependencies in the Build Command, e.g. npm install. Although, you’ve not given a lot to go on.

Alan

I have put there “npm ci”, I changed it to “npm install” and now ‘build succesful’. Thank you…

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.