A minimal starter to quickly get started with iExec DataProtector and React.
This project is a simple starter that allows you to:
- Connect a Web3 wallet (MetaMask, Privy, etc.)
- Protect data with iExec DataProtector
- Grant access to protected data
- Discover basic iExec features
Included features:
- β Wallet connection with Privy (MetaMask, embedded, etc.)
- β Data protection with iExec DataProtector
- β Multi-chain support (iExec Sidechain, Arbitrum)
- β Simple and clean user interface
- β Built with React, TypeScript, and Tailwind CSS
- Clone the project:
git clone https://github.com/iExecBlockchainComputing/iexec-react-starter.git
cd iexec-react-starter- Install dependencies:
npm install-
Configure Privy:
- Go to https://dashboard.privy.io
- Create a project and copy your Privy App ID
-
Configure environment variables:
# Create a .env file
VITE_PRIVY_APP_ID=your_privy_app_id- Start the project:
npm run devYour app will be available at http://localhost:5173
- MetaMask
- Coinbase Wallet
- Brave Wallet
- WalletConnect
- Zerion
β Other wallets may not work with iExec SDKs on Bellecour.
src/
βββ components/
β βββ WelcomeBlock.tsx # Welcome component
βββ config/
β βββ privyConfig.ts # Privy configuration
βββ context/
β βββ ContextProvider.tsx # Global providers
βββ utils/
β βββ normalizeChainId.ts # Utility for chainId normalization
βββ App.tsx # Main app logic
βββ index.css # Global styles
- Connection: Use Privy to connect your wallet
- Protection: Enter data name and content to protect
- iExec: Data is encrypted and stored via DataProtector
- Result: You receive the address and metadata of protected data
- iExec Sidechain (Bellecour) - Chain ID: 134
- Arbitrum One - Chain ID: 42161
- Arbitrum Sepolia - Chain ID: 421614
This starter is intentionally minimal. You can extend it with:
- More iExec features (compute, marketplace, Web3Mail)
- Advanced data management interface
- Protected dataset marketplace
- Integration with other iExec services
- Custom iExec applications
- Data monetization features
# Development server
npm run dev
# Build for production
npm run build
# Lint code
npm run lintHappy coding with iExec & Privy! πβ¨