- Single Page Application with 2 APIs and 3 components.
- APIS
- Stocks data via a GET request
- Carts data via GET and POST request
- Components
- Date picker for stock data
- Buy stock data
- Carts data of bought stock
- APIS
App on heroku here:
- The tech stack for this application is JavaScript/React/Redux for front end and Ruby on Rails for backend with PostsreSQL database.
- Interactive components for the date component and buying stock components.
- git clone repository
- Run rails API server:
$ cd stock-app
stock-app $ bundle
stock-app $ rails db:migrate
stock-app $ rails db:seed
stock-app $ rails s
- Run frontend React server:
stock-app $ cd frontend
frontend $ yarn install
frontend $ PORT=4000 yarn --cwd frontend start
- Or to run both servers together using heroku, run command:
$ yarn heroku
- View frontend at localhost:4000 and backend at localhost:3000/api/carts