Deployed: usedapp-example.vercel.app
-
DAppProvider
- main component, wraps around other Provider components which provide custom hooks for chain, block handling -
custom React Hooks for simpler (React native-ish) state management, abstracts from a lot of the complexities of even using
ethers
,web3
. Also updates components as new blocks are mined.useEthers
wraps aronudethers
provider
to get wallet, network datauseContractCalls
for specific contract calls and return values- source
-
custom
Models
for data models, but additional functions to handle data presentation & formatting e.g. currency conversion, timestamps etc. -
Helpers: more presentation, utilities functions
getExplorerTransactionLink
points to etherscan, bscscan etc.- address management including truncation, equals/matching etc.