Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .env.local
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,7 @@ VITE_OAUTH_CLIENT_UUID=f1f02e3d-c193-4438-b5fb-a27ef2f3a268
VITE_OAUTH_CLIENT_REDIRECT_URI=http://localhost:3000/oauth/callback

# Your sale contract address
VITE_SALE_CONTRACT_ADDRESS=0x439A7E681A71B1F3297e2c1b9c35bf226Ee24809
VITE_SALE_CONTRACT_ADDRESS=0x51BcE35d57833253EAccd6901e95eb6772aFfc8D

# Address of the payment token
VITE_PAYMENT_TOKEN_ADDRESS=0x036CbD53842c5426634e7929541eC2318f3dCF7e # USDC
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should probably also support multiple?

9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@ pnpm dev

The app will be available at `http://localhost:3000`.

The example uses a [SettlementSale](https://github.com/sunrisedotdev/sonar/blob/main/contracts/src/SettlementSale.sol) contract on Base Sepolia.

In order to test committing funds, you will need to have USDC to commit and ETH to pay for the gas.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the contract now also supports USDT, so might be worth noting? USDT is a bit easier in practice since one can directly mint from the contract


Faucets:

- USDC: <https://faucet.circle.com/>
- ETH: <https://docs.base.org/base-chain/tools/network-faucets>

## What This Example Demonstrates

- **Provider setup** — configuring `SonarProvider` with wagmi and React Query
Expand Down
343 changes: 0 additions & 343 deletions src/ExampleSaleABI.ts

This file was deleted.

7 changes: 3 additions & 4 deletions src/Provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
import { ConnectKitProvider, getDefaultConfig } from "connectkit";
import { SonarProvider } from "@echoxyz/sonar-react";
import { sonarConfig } from "./config";
import { sepolia } from "wagmi/chains";
import { baseSepolia } from "wagmi/chains";

const config = createConfig(
getDefaultConfig({
chains: [sepolia],
chains: [baseSepolia],
transports: {
[sepolia.id]: http(),
[baseSepolia.id]: http(),
},

// Required API Keys
Expand All @@ -35,4 +35,3 @@ export function Provider({ children }: { children: React.ReactNode }) {
</SonarProvider>
);
}

Loading