Skip to content

Getting Started

Garett Tok Ern Liang edited this page Sep 16, 2019 · 3 revisions

Setting up the front-end

1) Check for your Node version

$ node -v

If the above command results in an error, download the latest Node version here.

2) Check for your Yarn version

$ yarn -v

If the above command results in an error, download the latest Yarn version here.

3) Clone the repo into your working directory

$ git clone https://github.com/WilliamsStudentsOnline/wso-react.git

or

$ git clone [email protected]:WilliamsStudentsOnline/wso-react.git

4) Install the necessary dependencies

$ yarn

You should be all set! To get started, run

$ yarn start

to launch a development build, which includes Hot Module Reload(HMR), where changes you make will be instantly reflected without having to restart the server. Open http://localhost:3000 to view it in the browser. At this point in time, you shouldn't be able to view any bulletins (or surveys, etc, anything that requires data from the database), because the backend is not set up yet.

Setting up the back-end

Communicating with the Backend

  1. Set up the backend as per the instructions in the wso-go repository.
  2. Run the wso-go server via make run-dev.
  3. Run the React development sever via yarn start.

The development server is set to communicate to the backend via a proxy, allowing all HTTP requests can thus be made to /path/to/endpoint without further settings.

Congratulations, you have it running on your local setup!

Problems?

Create an issue or inform Garett on Slack. Be sure to pay it forward by editing this page with the steps you took to troubleshoot in order to ensure that new users do not encounter the same issues.

Clone this wiki locally