0.3.9 • Published 3 months ago
@le7el/web3_wallet v0.3.9
Web3 Wallet
Libary to connect and interact with web3 wallets Supported wallet providers: metamask, wallet-connect
Installation
npm install @le7el/web3_wallet
Getting started
This library exposes multiple publicly accesible methods, which could help in different web3 wallet use cases
Typical library usage for connecting a wallet and listen for its changes:
import { useProvider, connectWallet, listenWallet } from '@le7el/web3_wallet'
useProvider('metamask')
.then(connectWallet)
.then(connectedWalletAddress => {
console.log('wallet connection success')
})
.then(() => {
// in case when you need to listen on wallet changes, like: account changed or network changed,
// you'll also need to call listenWallet with approproate callbacks
const onWalletChange = (newWalletAddress) => {}
const onWalletError = (error) => {}
listenWallet(onWalletChange, onWalletError)
})
.catch(error => {
console.log('wallet connection failed')
})
0.3.9
3 months ago
0.3.8
3 months ago
0.3.7
3 months ago
0.3.0
3 months ago
0.3.6
3 months ago
0.3.5
3 months ago
0.3.2
3 months ago
0.3.1
3 months ago
0.3.4
3 months ago
0.3.3
3 months ago
0.2.9
12 months ago
0.2.8
1 year ago
0.2.7
1 year ago
0.2.6
1 year ago
0.2.3
1 year ago
0.2.2
1 year ago
0.2.5
1 year ago
0.2.4
1 year ago
0.1.23
1 year ago
0.2.1
1 year ago
0.2.0
1 year ago
0.1.22
1 year ago
0.1.21
1 year ago
0.1.20
1 year ago
0.1.19
1 year ago
0.1.18
1 year ago
0.1.17
1 year ago
0.1.16
1 year ago
0.1.15
1 year ago
0.1.14
1 year ago
0.1.13
1 year ago
0.1.12
1 year ago
0.1.11
1 year ago
0.1.10
1 year ago
0.1.9
1 year ago
0.1.8
1 year ago
0.1.7
1 year ago