https://github.com/ajit24/test-2406-q-4c47a416d7c8414c87fc09bd627985b0-146780-react-16.9-npm-in-docker
PAT-3 CodeJudge
https://github.com/ajit24/test-2406-q-4c47a416d7c8414c87fc09bd627985b0-146780-react-16.9-npm-in-docker
Last synced: 8 months ago
JSON representation
PAT-3 CodeJudge
- Host: GitHub
- URL: https://github.com/ajit24/test-2406-q-4c47a416d7c8414c87fc09bd627985b0-146780-react-16.9-npm-in-docker
- Owner: Ajit24
- Created: 2022-05-06T10:33:46.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-05-06T09:39:09.000Z (over 3 years ago)
- Last Synced: 2025-01-02T04:14:31.213Z (9 months ago)
- Size: 0 Bytes
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cj-app
React SPAIMPORTANT NOTES (In case Backend Service API Integration is required):
1. The backend endpoint host url can be accessed using "process.env.REACT_APP_API_URL" property. An example is shown in index.js.
2. PLEASE USE THIS PROPERTY ("process.env.REACT_APP_API_URL") WHEN YOU ARE TRYING TO CALL A BACKEND API. ALSO DON'T CHANGE THIS PROPERTY ELSE THE APP WILL NOT BUILD PROPERLY AND YOUR SUBMISSION WILL NOT BE SCORED.
3. In order to start the server in your local system, please run one of the below commands based on your Operating system:
- Windows (cmd.exe): set "REACT_APP_API_URL=" && npm start
- Windows (Powershell): ($env:REACT_APP_API_URL = "") -and (npm start)
- Linux, macOS (bash): REACT_APP_API_URL= npm startPROJECT BUILD STEPS (Make sure that your project is getting built successfully):
Pre-requisites:
1. Install http-server module (https://www.npmjs.com/package/http-server).
2. Install node and npmSteps:
1. Go to the project root directory.
2. Run the following commands in the terminal/command line to build the app:
- npm install
- npm run build
3. Please make sure that your project is built successfully.
4. Run the following commaand in the terminal/command-line to start the app:
- npm start
CLOUD-IDE SETUP STEPS(follow the below steps in case you are using the Cloud IDE instead of your Local IDE):1. Please run the below commands from the project root in a separate terminal to setup live run support in Cloud IDE:
- chmod 0755 ./chrome-test-setup.sh
- sh ./chrome-test-setup.sh
2. Make the port 9515 public