Skip to content

ankur-JA/NameSwap

Repository files navigation

🌐 ENS-bound Nameswap

Seamless ETH to USDC swaps with integrated ENS reverse name resolution

A modern DeFi application that combines ENS naming with efficient token swapping, built on Ethereum mainnet using Uniswap V3.

✨ Features

  • 🏷️ ENS Integration - Set reverse ENS names for smart contracts
  • 💱 Instant Swaps - ETH to USDC conversion via Uniswap V3
  • ⚙️ Customizable - Adjustable fee tiers and slippage protection
  • 🎨 Modern UI - Beautiful, responsive interface built with Next.js
  • 🔒 Secure - Audited smart contracts with mainnet-ready deployment

🚀 Quick Start

Prerequisites

Local Development

# Clone the repository
git clone https://github.com/your-username/nameswap.git
cd nameswap

# Install dependencies
yarn install

# Start local blockchain
yarn chain

# Deploy contracts
yarn deploy

# Launch frontend
yarn start

Visit http://localhost:3000 to access the application.

📦 Deployment

Smart Contract (Mainnet)

  1. Configure environment variables:
# packages/foundry/.env
DEPLOYER_PRIVATE_KEY=your_private_key
ALCHEMY_API_KEY=your_alchemy_key
ETHERSCAN_API_KEY=your_etherscan_key
  1. Deploy to mainnet:
./deploy-mainnet.sh

Frontend (Vercel)

  1. Push to GitHub
  2. Import repository in Vercel
  3. Set root directory to packages/nextjs
  4. Add environment variables and deploy

See DEPLOYMENT.md for detailed instructions.

🏗️ Architecture

  • Smart Contracts - Solidity contracts with Foundry framework
  • Frontend - Next.js 14 with TypeScript and Tailwind CSS
  • Blockchain - Ethereum mainnet integration
  • DEX - Uniswap V3 for optimal swap routing

📄 Contract Addresses

Contract Address
ENS ReverseRegistrar 0xa58E81fe9b61B5c3fE2AFD33CF304c454AbFc7Cb
Uniswap V3 SwapRouter 0xE592427A0AEce92De3Edee1F18E0157C05861564
WETH9 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2
USDC 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48

🛠️ Built With

📜 License

This project is licensed under the MIT License - see the LICENSE file for details.


Made with ❤️ for the Ethereum ecosystem

About

ENS-Bound Contract swaps ETH → USDC.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors