A donation website built with Next.js, Shadcn UI, and Tailwind CSS, integrated with BraidPay for secure USDC donations.
Before you begin, you'll need:
Clone the repository:
git clone https://github.com/braidpay/Code-Sample-Donation
cd Code-Sample-Donation
Install dependencies:
npm install
# or
yarn install
Create a .env
file in the root directory:
ALCHEMY_API_KEY=your_alchemy_api_key
Update the BraidPay payment link in app/DonateDialog.tsx
:
<iframe
src="https://app.braidpay.com/p/your_payment_link_id"
className="w-full h-full"
allow="payment"
/>
Update the wallet address in app/api/donations/route.ts
:
params: [
{
toAddress: 'your-wallet-address',
contractAddresses: ['donation-coin-contract-address']
}
]
Run the development server:
npm run dev
# or
yarn dev
Edit app/layout.tsx
to update:
app/globals.css
tailwind.config.ts
globals.css
The template uses Shadcn UI components, which can be customized in the components/ui
directory.
ALCHEMY_API_KEY
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.
If you encounter any issues or have questions: