Stock Up is a simple stock trading app built for a technical assessment.
A user can create an account and portfolio, search for stocks by ticker symbol, purchase shares, and view a transaction record. The app uses Alpha Vantage Stocks API to fetch stock prices every 60 seconds and provide current prices for a dynamically rendered portfolio that displays ticker symbol, shares, and current stock price, colorized to indicate performance. The application uses authorization for a secure user experience. Due to frequency limitations from the stocks API, there are some loading issues if user activity is frequent or volumous. That issue and other needed refactors will be done at a future date.
$tock^ - The Premiere Stock Portfolio Simulator
- Dan Romans | dangrammer
Front End (Client):
- HTML5 (JSX)
- CSS3 (customized - no templates)
- ES6 JavaScript
- React ^16.13.1
- React-Dom ^16.13.1
- React-Redux ^7.2.0
- React-Router ^5.2.0
- React-Router-Dom ^5.2.0
- React-Scripts ^3.4.0
- Redux ^4.0.5
- Redux-thunk ^4.0.5
- Redux-Devtools-Extension ^2.13.8
Back End (API):
- ruby 2.6.1
- rails ~> 6.0.1
- postgreSQL
- fast_jsonapi
- rack-cors
- bcrypt ~> 3.1.7
- jwt ~> 2.2, >= 2.2.1
- dotenv-rails
- fork (optional) then clone or download this repository to local machine
- use text editor and/or terminal to navigate into
stockup-api
directory - run
bundle install
(orbundle i
) in terminal to install necessary dependencies - run
rails db:create
in terminal to create database - run
rails db:migrate
in terminal to initialize database - create secret key:
- create a
.env
file in root directory - write secret key for JWT in
.env
file:JWT_SECRET_KEY=KEY_HERE # see note below
- create a
- run
rails s
in terminal to run server in browser at http://localhost:3000/
*Note: KEY_HERE
_should be characters of your choice. Always include
.env
file in .gitignore
file.
- use text editor and/or terminal to navigate into
stockup-client
directory - run
npm install
(ornpm i
) in terminal to install necessary dependencies - create secret key:
- create a
.env
file in root directory - write secret key for Alpha Vantage Stocks API in
.env
file:REACT_APP_API_KEY=KEY_HERE
- create a
*Note: KEY_HERE
should be an individually assigned key from Alpha Vantage Stocks API._ Always include .env
file in .gitignore
file.
- run
npm start
in terminal to launch the app in browser
*Note: If backend server is already running, it will be running on http://localhost:3000/. After
running npm start
, follow prompt and enter y
in terminal to run frontend on alternate port.