*To Run this application you will need both Nodejs and FLask(python) and Requests(python) installed onto your device *
*To Install Nodejs please go to https://nodejs.org/en/download/ and to install Flask please go to https://flask.palletsprojects.com/en/2.0.x/installation/ and to install Requests please go to https://pypi.org/project/requests/ *
This project is a web app that is built using Svelte.js for the front end and Flask(Python) for the back end. The purpose of this application is to fetch the data from two different sources for both Bitcoin and Ethereum and displays both buy and sell price for both sources. The application will also recommend the user on which exchange source to trade on along with the price difference between sources.
*Note that you will need to have [Node.js], [Flask(Python)] and [Requests(Python)] installed. *
For Bitcoin:
for Ethereum:
The backend consists of 4 Api's that call onto its corresponding exchange rate api to fetch the exchange rate data in json format. The fron end calls on the backend api's and retreives the exchange rate data. The front end then parses the data and displays it accordingly.
Main code is in src/App.svelte
The server/api are in server.py for develppment server and server2.py for production server
*These installation an Deployment Instructions are meant for MAC OS * Download the Project
git clone https://github.com/humzahokadia/BTC-ETH-Exchange-Rate-APP-Svelte-Flask-.git
next navigate to the folder
cd BTC-ETH-Exchange-Rate-APP-Svelte-Flask-
first set up the environment
export FLASK_APP=server.py
export FLASK_ENV=development
flask run
then start the server
python server.py
in a new terminal tab navigate to the public folder
cd public
next install dependencies
npm install
and finally deploy the front end
npm run build
The application is now running...
Navigate to localhost:5000.
*To Run this application with a production server you will need Waitress(python) installed onto your device *
*To Install Waitress please go to https://pypi.org/project/waitress/ *
first start the server
python server2.py
in a new terminal tab navigate to the public folder
cd public
next install dependencies
npm install
and finally deploy the front end
npm run build
The application is now running...
Navigate to localhost:8080.
or
Navigate to 0.0.0.0:8080.