Skip to content

brianonchain/diversifi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

DiversiFi DApp is a test DApp where users can deposit/withdraw USDC on the networks Ethereum Sepolia and Polygon. The DApp showcases a user-friendly UI for approve & transfer, interactive line charts, and a transaction history UI powered by The Graph.

Visit https://diversifi.vercel.app/ to test it out!

Contract Addresses

Polygon: 0x599559Ed394ADd1117ab72667e49d1560A2124E0
Sepolia: 0xd8d86fe48323Cd4A630cef4f7825fCB22dEF94E9

NextJS Data Fetching

Vault description and details are fetched from an external database using Next.js's unstable_cache in the page.tsx Server Component. This allows immediate loading of the Vault Description and fewer queries to the database.

User-specific data (balances, tx history, etc.) are fetched on the client-side using React Query.

(Separate Project) Store Payment Metadata in Logs. Test it out:

  1. Get Sepolia ETH from Alchemy Faucet and USDC from Circle’s faucet
  2. Go to https://diversifi.vercel.app/pay and connect your “Customer Wallet” that holds these tokens
  3. Add a few items to the Shopping Cart. Then, enter a Merchant Address (an account you control). Finally, click “Send”.
  4. Go to https://diversifi.vercel.app/merchantDash and connect your “Merchant Wallet”; view payment details

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published