Function createEVMSwapper
createEVMSwapper ( provider ) : Raw < { chainType : ChainTypes ; chains : Computed < BridgeChain [] > ; isInitialized : Ref < boolean > ; provider : Ref < IProvider > ; approve ( token , operator ) => Promise < void | TransactionResponse > ; approveIfNeeded ( token , operator , amount ? ) => Promise < void | TransactionResponse > ; execute ( args , multiplePaymentOpts ? ) => Promise < TransactionResponse > ; getChainById ( id ) => void | BridgeChain ; getDestinationTx ( sourceChain , sourceTxHash ) => Promise < DestinationTransaction > ; getSupportedChains ( ) => Promise < BridgeChain [] > ; init ( ) => Promise < void > ; isApproveRequired ( token , operator , amount ? ) => Promise < boolean > ; } >
Returns Raw < { chainType : ChainTypes ; chains : Computed < BridgeChain [] > ; isInitialized : Ref < boolean > ; provider : Ref < IProvider > ; approve ( token , operator ) => Promise < void | TransactionResponse > ; approveIfNeeded ( token , operator , amount ? ) => Promise < void | TransactionResponse > ; execute ( args , multiplePaymentOpts ? ) => Promise < TransactionResponse > ; getChainById ( id ) => void | BridgeChain ; getDestinationTx ( sourceChain , sourceTxHash ) => Promise < DestinationTransaction > ; getSupportedChains ( ) => Promise < BridgeChain [] > ; init ( ) => Promise < void > ; isApproveRequired ( token , operator , amount ? ) => Promise < boolean > ; } >
Description
Instead of using this function directly, run token swaps as transactions with the @rarimo/nft-checkout package. For more information about swaps, see Swapping tokens in the Rarimo documentation.