Krypt

Krypt

DeFi app to borrow stable coin in exchange for ETH

12

The problem Krypt solves

This Dapp allows people to borrow YUSD(yangit USD which is a stable coin) in exchange for an amount of ETH that they decide to deposit. When the user is done arbitraging with the YUSD they can exchange it back for an amount of ETH as per the exchange rate at the time. This is a trustless way of obtaining loans with no middle men and the only fees that you will be paying are gas fees which is much less than what would be charged by a bank.

Challenges I ran into

ChainLink DataFeeds

One of the biggest issues i ran into was setting up Chainlink Data feeds locally. Since there is no way to test the Dapp without a local setup of the chainlink contracts. Figured out a way to do this using Hardhat deploy (even though it was a pain to setup), it made the whole process of testing and iterating on the contract so much smoother since with ethers it keeps track of all the deploys(both local and testnet), it also lets you setup mock contracts during development which is such a blessing cause otherwise running scripts each time after restarting the local node would be very painfull.

Typing

Apart from this since i worked with typescript on the project it was a little difficult initally to get the types for the contracts till i started using typechain which automatically generated types for the contracts.

Discussion