I originally tried deploying with just the script “yarn”, but this was not working. I was getting the error “react-scripts not found”.
I instead resorted to using “yarn; yarn build”, and the previous error went away. However, another error came about.
“Build folder build does not exist”
I don’t understand how the build folder build doesn’t exist. “yarn build” was just run. When I run “yarn build” locally, it creates the build folder called build. I set my publish directory to “src/build”, just as the Render docs suggest.
It does seem to point to your build path is incorrect, as the error shows. Is all your code in src, e.g. the package.json also? At a guess I would think the build folder is being created in the root of the project. I’d try removing any “Root Directory” from your service settings.
As an aside, dependencies are installed automatically on Static Sites, so your Build Command could likely just be yarn build.