.send()
Sends all batches and transactions
The
.send()
function simply sends all the <EtherspotBatches />
, which contain all <EtherspotBatch />
and <EtherspotTransaction />
components to the blockchain via the Etherspot platform.You must always estimate before sending
Estimating first performs imporant transaction cost calculations that are required before sending.
Whenever you are ready to send your transaction to the blockchain, you simply need to call .send() as shown below.
import {
useEtherspotUi,
} from '@etherspot/transaction-kit';
// Later in the main component function...
const { send } = useEtherspotUi();
// And when you're ready to end your transaction(s)...
send(); // This is also a Promise
// Your transactions are now being sent to the blockchain
By calling the above function, you have sent the transactions to the Etherspot platform, and we'll take care of it from here to ensure that the transactions are executed on the blockchain.
Last modified 1mo ago