Use Contract Artifacts for Parsing Event Logs
Closed this issue · 2 comments
bh2smith commented
We shouldn't be hard-coding those event topics and manually parsing the topics/data.
Better approach to depend on https://www.npmjs.com/package/@cowprotocol/contracts and use the contract ABI with ethers.js parsing library to get typed objects with the relevant fields (see this tutorial).
Originally posted by @fleupold in #182 (comment)
bh2smith commented
Note that the problem I for see here is the bulkiness of depending on all of openzeppelin just for an erc20 token interface. Maybe there is a way to only require individual artifacts.
More on this in #182 (comment)