ethers-query
React Query hooks for ethers.js
Simple. Powerful. Type-safe.
ethers-query combines the power of ethers.js with the elegant caching and state management of React Query. Build Web3 applications with confidence using our type-safe hooks and components.
Features
- 🔌 Easy wallet integration
- 📊 Smart contract interactions
- 💾 Automatic caching
- 🔄 Real-time updates
- 📝 Message signing
- 🛠️ Full TypeScript support
Quick Start
import { EthersQueryProvider, Client } from 'ethers-query'
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
const client = new Client({
connectors: [new InjectedConnector()]
})
const queryClient = new QueryClient()
function App() {
return (
<QueryClientProvider client={queryClient}>
<EthersQueryProvider client={client}>
<YourApp />
</EthersQueryProvider>
</QueryClientProvider>
)
}
Easy to Use
Start building Web3 apps in minutes with our intuitive hooks and components. No complex setup required.
Focus on What Matters
Let ethers-query handle the complexities of blockchain interactions while you focus on building great user experiences.
Powered by React Query
Enjoy automatic caching, real-time updates, and optimistic UI with the battle-tested React Query library.