Crypto Trading
A demo trading visualisation using Go and React
This app comprises a backend order book, price ticker and WebSocket interface - written in Go - to power a simple UI visualisation - written in React.
The backend service connects to a firehose of currency exchange prices (via GDAX public price feed) and broadcasts those ticks over a websocket to any subscribed client. Clients sample those ticks to show the current ask price and volume on an animated scale.
To subscribe to a currency pair, the client sends a message in the following format:
client.subscribe("BTC-USD");
Getting started
- Ensure
yarn
is installed (https://yarnpkg.com) - Fetch project:
go get gitlab.com/gschambers/crypto-trading
- Install client dependencies:
yarn install
- Build client:
yarn build
- Build server:
go build
- Run:
./crypto-trading
and visithttp://localhost:3000
TODO
- Implement visualisations for historical market data
- Simulate market, limit and stop order placing