Skip to content

gardenfi/demo-dapp

Repository files navigation

Demo App

This project demonstrates how to use the Garden SDK to create a simple dApp for swapping from WBTC to BTC.

Note

For better developer experience, we are conducting the swap on a local network, but you can do the same on Testnet or Mainnet by changing the parameters.

Features

  • Merry : Provides a comprehensive environment for multichain operations.
  • Swap Interface: Easily swap from WBTC to BTC.
  • Transaction Management: Track and display the latest transactions.
  • Garden SDK Integration: Uses Garden SDK to make the swap possible.
  • State Management: We use zustand for state management.

Environment Setup

To improve the developer experience, we will be using Merry to set up the multichain environment necessary for performing a swap. This setup includes all essential components such as the Orderbook, Filler, Faucet, and nodes for Bitcoin, Ethereum, and Arbitrum.

  1. Install Merry
curl https://get.merry.dev | bash
  1. Start Merry
# Start Merry with explorer
merry go

or

# Start Merry without explorer
merry go --headless
  1. Fund your EVM address
 merry faucet --to <EVM Address>

Project Setup

  1. Clone the repository
git clone https://github.com/gardenfi/demo-app
cd demo-app
  1. Install dependencies
bun install
  1. Run the development server
bun run dev

The dApp should look something like this

final_dapp

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published