This project was bootstrapped with Create React App.
A bid/ask spread trading simulation that consumes trade orders (limit order type) - built in React and Node
- Install nodemon globally
npm i nodemon -g
- Install server and client dependencies
npm i --save
cd client
npm i --save
cd ../
- Start server and client concurrently
npm start
Node server will stream order book's limit orders to client, which will process one order at a time (default set at 1 second) and display order detail in bid/ask screen. If an order can be filled partially or entirely, it will be filled at the order's price or better (limit order). Last Market Price indicates the most recent price filled.
* Room for improvement: In case of a tie in price, filling an order is not necessarily first come first served. One way this can be fixed is by using timestamp. *