Create React App
Create React App (often shortened to “CRA”) is the older, but still very common, way to make a React app. Here the folder you upload is called build (not dist).
How to recognize it
Section titled “How to recognize it”The package.json mentions react-scripts, and the commands use react-scripts build.
Building the folder
Section titled “Building the folder”-
Open a terminal in the project folder.
-
Install the pieces it needs (first time):
Terminal window npm install -
Build:
Terminal window npm run buildA
buildfolder appears. -
Upload the
buildfolder to Bailey.
The anti-blank-page setting
Section titled “The anti-blank-page setting”CRA uses absolute paths by default (ones starting with /). On a Bailey subdomain that’s fine, but if you hit a blank page, add this line to package.json:
{ "homepage": ".", "name": "my-app"}"homepage": "." switches to relative paths. Run npm run build again and re-upload build. → Why your site looks broken