Releases: thirdweb-dev/js
thirdweb@5.99.0
Minor Changes
-
#7003
58e343c
Thanks @joaquim-verges! - Breaking change: EIP-5792 supportWe've significantly improved our EIP-5792 apis, which come with some breaking changes:
New Functions Added
-
useSendAndConfirmCalls
- Description: Hook to send and wait for confirmation of EIP-5792 calls
- Returns: React Query mutation object with transaction receipts
- Example:
const { mutate: sendAndConfirmCalls, data: result } = useSendAndConfirmCalls(); await sendAndConfirmCalls({ client, calls: [tx1, tx2], }); console.log("Transaction hash:", result.receipts?.[0]?.transactionHash);
-
useWaitForCallsReceipt
- Description: Hook to wait for the receipt of EIP-5792 calls, perfect for splitting submitting the call and waiting for receipt
- Returns: React Query object with call receipts
- Example:
const { mutate: sendCalls, data: result } = useSendCalls(); const { data: receipt, isLoading } = useWaitForCallsReceipt(result);
Breaking Changes
useSendCalls
ChangesBefore
// mutation returns id a string const sendCalls = useSendCalls({ client });
After
// no longer needs client // mutation returns an object with id const sendCalls = useSendCalls();
Waiting for call receipts is now done separately, via the
useWaitForCallsReceipt
.Before
const { mutate: sendCalls, data: receipt } = useSendCalls({ client, waitForBundle: true, });
After
const { mutate: sendCalls, data: result } = useSendCalls(); const { data: receipt, isLoading } = useWaitForCallsReceipt(result);
You can also use the helper
useSendAndConfirmCalls
to combine both submitting and waiting for confirmation.const { mutate: sendAndConfirmCalls, data: receipt } = useSendAndConfirmCalls();
sendCalls
ChangesBefore:
// Old output type type SendCallsResult = string;
After:
// New output type type SendCallsResult = { id: string; client: ThirdwebClient; chain: Chain; wallet: Wallet; };
-
@thirdweb-dev/wagmi-adapter@0.2.76
@thirdweb-dev/wagmi-adapter@0.2.76
thirdweb@5.98.2
Patch Changes
-
#7009
5a13ad4
Thanks @gregfromstl! - Automatically trigger SIWE sign in when a wallet is connected -
#7011
98eda9d
Thanks @gregfromstl! - Auto-login on autoconnect of IAW in all cases
@thirdweb-dev/wagmi-adapter@0.2.75
@thirdweb-dev/wagmi-adapter@0.2.75
thirdweb@5.98.1
Patch Changes
- #7004
6f1d4b1
Thanks @joaquim-verges! - Handle tx with value on engineAccount
@thirdweb-dev/wagmi-adapter@0.2.74
@thirdweb-dev/wagmi-adapter@0.2.74
@thirdweb-dev/service-utils@0.9.8
thirdweb@5.98.0
Minor Changes
-
#6874
e96ebba
Thanks @joaquim-verges! - EIP7702 support for in-app walletsYou can now turn your in-app wallets into smart accounts with 7702!
This lets you:
- sponsor transactions
- batch transactions
- add session keys
- and more!
simply pass the executionMode "EIP7702" to get started:
const wallet = inAppWallet({ executionMode: { mode: "EIP7702", sponsorGas: true, }, });
Keep in mind that this will only work on chains that support 7702.
@thirdweb-dev/wagmi-adapter@0.2.73
@thirdweb-dev/wagmi-adapter@0.2.73
thirdweb@5.97.3
Patch Changes
- #6974
5f6403b
Thanks @joaquim-verges! - Handle hex value format for smart wallet execution