This project was bootstrapped with Create React App.
- Clone this repo.
- If you have not done so, locally install yarn, node, and python 3.7. (Recommended: using Homebrew)
- Go to the root directory of the project, and set up the local virtual environment by the following commands:
pipenv --python 3.7 && pipenv install. - Install node dependencies with yarn:
yarn install --frozen-lockfile. - Within the root directory, create an
.envfile with the following configurations for our flask application:export FLASK_APP='api/app.py' export FLASK_ENV='development'
-
To start the app, run:
$ yarn start-frontend $ yarn start-backendin two separate tabs. These commands runs the React app and the flask server in development mode, and will reload when you make new changes to the code. Open http://localhost:3000 to view it in the browser.
-
To conduct frontend and backend tests, run:
$ yarn test-frontend $ yarn test-backendThese commands will respectively run the frontend and backend tests in
src/testsandapi/tests. -
After a
git commitis attempted, the pre-commit hooks specified in.pre-commit-config.yamlwill scan the proposed changes for reformatting & detecting stylistic / syntactical errors. Make sure you address those warnings / errors before pushing.