ContractEvents.addTransactionListener() method
Subscribe to transactions in this contract.
Example
contract.events.addTransactionListener((event) => {
console.log(event);
}
Signature:
addTransactionListener(listener: EventEmitter.ListenerFn): void;
Parameters
Parameter | Type | Description |
---|---|---|
listener | EventEmitter.ListenerFn | the callback function that will be called on every transaction |
Returns:
void
Remarks
Will emit an "event" object containing the transaction status ('submitted' and 'completed') and hash