-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(viem): export sendSupERC20 (#541)
- Loading branch information
1 parent
ab77241
commit dc8d997
Showing
48 changed files
with
263 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
[**@eth-optimism/viem**](../README.md) • **Docs** | ||
|
||
*** | ||
|
||
[@eth-optimism/viem](../README.md) / estimateSendSupERC20Gas | ||
|
||
# estimateSendSupERC20Gas() | ||
|
||
> **estimateSendSupERC20Gas**\<`TChain`, `TAccount`, `TChainOverride`\>(`client`, `parameters`): `Promise`\<`bigint`\> | ||
Estimates gas for [sendSupERC20](sendSupERC20.md) | ||
|
||
## Type Parameters | ||
|
||
• **TChain** *extends* `undefined` \| `Chain` | ||
|
||
• **TAccount** *extends* `undefined` \| `Account` | ||
|
||
• **TChainOverride** *extends* `undefined` \| `Chain` = `undefined` | ||
|
||
## Parameters | ||
|
||
• **client**: `Client`\<`Transport`, `TChain`, `TAccount`\> | ||
|
||
L2 Wallet Client | ||
|
||
• **parameters**: [`SendSupERC20Parameters`](../type-aliases/SendSupERC20Parameters.md)\<`TChain`, `TAccount`, `TChainOverride`, `DeriveChain`\<`TChain`, `TChainOverride`\>\> | ||
|
||
[SendSupERC20Parameters](../type-aliases/SendSupERC20Parameters.md) | ||
|
||
## Returns | ||
|
||
`Promise`\<`bigint`\> | ||
|
||
The estimated gas value. | ||
|
||
## Defined in | ||
|
||
[packages/viem/src/actions/sendSupERC20.ts:106](https://github.com/ethereum-optimism/ecosystem/blob/ab77241754eb52e5f63719e48141efd7250e972b/packages/viem/src/actions/sendSupERC20.ts#L106) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
[**@eth-optimism/viem**](../README.md) • **Docs** | ||
|
||
*** | ||
|
||
[@eth-optimism/viem](../README.md) / sendSupERC20 | ||
|
||
# sendSupERC20() | ||
|
||
> **sendSupERC20**\<`chain`, `account`, `chainOverride`\>(`client`, `parameters`): `Promise`\<[`SendSupERC20ReturnType`](../type-aliases/SendSupERC20ReturnType.md)\> | ||
Sends tokens to a target address on another chain. Used in the interop flow. | ||
|
||
## Type Parameters | ||
|
||
• **chain** *extends* `undefined` \| `Chain` | ||
|
||
• **account** *extends* `undefined` \| `Account` | ||
|
||
• **chainOverride** *extends* `undefined` \| `Chain` = `undefined` | ||
|
||
## Parameters | ||
|
||
• **client**: `Client`\<`Transport`, `chain`, `account`\> | ||
|
||
L2 Wallet Client | ||
|
||
• **parameters**: [`SendSupERC20Parameters`](../type-aliases/SendSupERC20Parameters.md)\<`chain`, `account`, `chainOverride`, `DeriveChain`\<`chain`, `chainOverride`\>\> | ||
|
||
[SendSupERC20Parameters](../type-aliases/SendSupERC20Parameters.md) | ||
|
||
## Returns | ||
|
||
`Promise`\<[`SendSupERC20ReturnType`](../type-aliases/SendSupERC20ReturnType.md)\> | ||
|
||
The sendSupERC20 transaction hash. [SendSupERC20ReturnType](../type-aliases/SendSupERC20ReturnType.md) | ||
|
||
## Defined in | ||
|
||
[packages/viem/src/actions/sendSupERC20.ts:77](https://github.com/ethereum-optimism/ecosystem/blob/ab77241754eb52e5f63719e48141efd7250e972b/packages/viem/src/actions/sendSupERC20.ts#L77) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
[**@eth-optimism/viem**](../README.md) • **Docs** | ||
|
||
*** | ||
|
||
[@eth-optimism/viem](../README.md) / simulateSendSupERC20 | ||
|
||
# simulateSendSupERC20() | ||
|
||
> **simulateSendSupERC20**\<`TChain`, `TAccount`, `TChainOverride`\>(`client`, `parameters`): `Promise`\<[`SendSupERC20ContractReturnType`](../type-aliases/SendSupERC20ContractReturnType.md)\> | ||
Simulate contract call for [sendSupERC20](sendSupERC20.md) | ||
|
||
## Type Parameters | ||
|
||
• **TChain** *extends* `undefined` \| `Chain` | ||
|
||
• **TAccount** *extends* `undefined` \| `Account` | ||
|
||
• **TChainOverride** *extends* `undefined` \| `Chain` = `undefined` | ||
|
||
## Parameters | ||
|
||
• **client**: `Client`\<`Transport`, `TChain`, `TAccount`\> | ||
|
||
L2 Public Client | ||
|
||
• **parameters**: [`SendSupERC20Parameters`](../type-aliases/SendSupERC20Parameters.md)\<`TChain`, `TAccount`, `TChainOverride`, `DeriveChain`\<`TChain`, `TChainOverride`\>\> | ||
|
||
[SendSupERC20Parameters](../type-aliases/SendSupERC20Parameters.md) | ||
|
||
## Returns | ||
|
||
`Promise`\<[`SendSupERC20ContractReturnType`](../type-aliases/SendSupERC20ContractReturnType.md)\> | ||
|
||
The contract functions return value. [SendSupERC20ContractReturnType](../type-aliases/SendSupERC20ContractReturnType.md) | ||
|
||
## Defined in | ||
|
||
[packages/viem/src/actions/sendSupERC20.ts:132](https://github.com/ethereum-optimism/ecosystem/blob/ab77241754eb52e5f63719e48141efd7250e972b/packages/viem/src/actions/sendSupERC20.ts#L132) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
packages/viem/docs/type-aliases/SendSupERC20ContractReturnType.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
[**@eth-optimism/viem**](../README.md) • **Docs** | ||
|
||
*** | ||
|
||
[@eth-optimism/viem](../README.md) / SendSupERC20ContractReturnType | ||
|
||
# SendSupERC20ContractReturnType | ||
|
||
> **SendSupERC20ContractReturnType**: `ContractFunctionReturnType`\<*typeof* [`superchainTokenBridgeABI`](../variables/superchainTokenBridgeABI.md), `"nonpayable"`, `"sendERC20"`\> | ||
## Defined in | ||
|
||
[packages/viem/src/actions/sendSupERC20.ts:56](https://github.com/ethereum-optimism/ecosystem/blob/ab77241754eb52e5f63719e48141efd7250e972b/packages/viem/src/actions/sendSupERC20.ts#L56) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
[**@eth-optimism/viem**](../README.md) • **Docs** | ||
|
||
*** | ||
|
||
[@eth-optimism/viem](../README.md) / SendSupERC20ErrorType | ||
|
||
# SendSupERC20ErrorType | ||
|
||
> **SendSupERC20ErrorType**: `EstimateContractGasErrorType` \| `WriteContractErrorType` \| `ErrorType` | ||
## Defined in | ||
|
||
[packages/viem/src/actions/sendSupERC20.ts:65](https://github.com/ethereum-optimism/ecosystem/blob/ab77241754eb52e5f63719e48141efd7250e972b/packages/viem/src/actions/sendSupERC20.ts#L65) |
Oops, something went wrong.