Skip to content
This repository has been archived by the owner on Aug 5, 2024. It is now read-only.

Commit

Permalink
Update page.mdx (#316)
Browse files Browse the repository at this point in the history
Signed-off-by: Joaquim Verges <[email protected]>
  • Loading branch information
joaquim-verges authored Apr 4, 2024
1 parent b458548 commit f768d50
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/app/typescript/v5/transactions/send/page.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,19 @@ console.log("cost in ether", gasCost.ether);
Simulate a transaction to see if it would be successful.

```ts
import { prepareContractCall, simulateTransaction } from "thirdweb";
import { simulateTransaction } from "thirdweb";

const result = await simulateTransaction({ transaction });
console.log("simulation result", result);
```

## encode

Encode a transaction data to be used later

```ts
import { encode } from "thirdweb";

const data = await encode(transaction);
console.log("encoded data", data);
```

0 comments on commit f768d50

Please sign in to comment.