How to install package.json inside a sub folder

I am trying to use packages from a subfolder
“heroku-prebuild”: "npm install --prefix www " if I was using Heroku
I don’t know how to get this done on Netlify
dependencies in the subfolder are needed for my application to run

Is the entire application in the sub-directory? If so you might check out the monorepo documentation

Otherwise, add all the dependencies to the package.json at the root of the project.

Failing that can you share the build settings you are currently using and the repository you are deploying from.

“postinstall”: “cd www && npm install”
was what i used