dex-subgraph
dex-subgraph copied to clipboard
Calculate price for orders, trades, and average traded price
Make it easier for consumers to check the price by doing the calculation already. For that, we need to take into account the decimals of the tokens.
Includes
- [ ] Limit price for an order
- [ ] Average traded price for the order. As the weighted avg price of all the orders ---> sum(soldTokens) / sum(soldTokens)
- [ ] Trade price