Creates and returns a typed Ethers v6 contract instance for the Staking precompile contract. This contract is used for interoperability between the EVM and Cosmos.
import { getStakingPrecompileEthersV6Contract, parseSei } from '@sei-js/evm';import { ethers } from 'ethers';const provider = new ethers.BrowserProvider(window.ethereum); // or any other providerconst signer = await provider.getSigner();const accounts = await provider.send('eth_requestAccounts', []);const contract = getStakingPrecompileEthersV6Contract(signer);const response = await contract.delegate('0xVALIDATOR_ADDRESS', parseSei(1));console.log('Delegate Response:', response); Copy
import { getStakingPrecompileEthersV6Contract, parseSei } from '@sei-js/evm';import { ethers } from 'ethers';const provider = new ethers.BrowserProvider(window.ethereum); // or any other providerconst signer = await provider.getSigner();const accounts = await provider.send('eth_requestAccounts', []);const contract = getStakingPrecompileEthersV6Contract(signer);const response = await contract.delegate('0xVALIDATOR_ADDRESS', parseSei(1));console.log('Delegate Response:', response);
A Provider (read-only) or ethers.Signer to use with the contract.
The typed contract instance for interacting with the Staking precompile contract.
Creates and returns a typed Ethers v6 contract instance for the Staking precompile contract. This contract is used for interoperability between the EVM and Cosmos.
Example