contractHandler
contractHandler(
client
,options
?):ContractHandler
Creates a tree-shakable instance of contractHandler
for handling contract interactions with the Ethereumjs EVM.
This function uses callHandler
under the hood to execute contract calls.
Note: This is the internal logic used by higher-level APIs such as tevmContract
.
Parameters
• client: TevmNode
<"fork"
| "normal"
, object
>
The TEVM base client instance.
• options? = {}
Optional parameters.
• options.throwOnFail?: undefined
| boolean
= true
Whether to throw an error on failure.
Returns
The contract handler function.
Throws
If throwOnFail
is true, returns TevmCallError
as value.