These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
What things you need to install the software.
- Node.js
- npm
A step by step series of examples that tell you how to get a development environment running.
- Clone the repo:
git clone https://github.com/Cath3dr4l/VRS-Frontend
- Move to the project directory:
cd VRS-Frontend
- Install dependencies:
npm install
- Start the development server:
npm start
After setting up the development server, you need to create a .env
file in the root directory of the project to store environment variables:
- Create a new file named
.env
in the root directory of the project. - Add the following line to the
.env
file:REACT_APP_RZP_KEY_ID=your_razorpay_api_key_id (Replace `your_razorpay_api_key_id` with your actual Razorpay API Key ID.)
In the package.json
file, you'll find a line that looks like this:
"proxy": "http://localhost:9000",
This line is used to specify the server that the client-side (React) part of the application should proxy to in development. This is necessary to avoid CORS issues when the server's URL is different from the client's URL.
In this case, the server is running on http://localhost:9000, so that's what we've set the proxy to. This means that when you make requests to /api/some-endpoint, the development server will automatically proxy your request to http://localhost:9000/api/some-endpoint.
If your server is running on a different URL, you should change the proxy setting to match your server's URL.
For the backend code, please refer to the VRS Backend repository.