Skip to content

Releases: wevm/viem

[email protected]

21 Dec 23:36
8b8a522

Choose a tag to compare

Patch Changes

[email protected]

18 Dec 20:29
d0dc0b0

Choose a tag to compare

Patch Changes

[email protected]

17 Dec 05:15
aa7a84d

Choose a tag to compare

Patch Changes

[email protected]

17 Dec 02:52
87d8182

Choose a tag to compare

Minor Changes

  • #4107 b423fc17eba4f9f0648f72f5358a8e5ed9d5f092 Thanks @tmm! - Added experimental named tuple support for contract-related actions and utilities.

  • #4147 734d99d9da4b76f9aa985a800213b4ba581607df Thanks @jxom! - Added first-class support and extension for Tempo.


    Attaching a Tempo chain to your client grants your transaction actions with Tempo superpowers like batched calls and external fee payer capabilities.

    import { createClient, http } from "viem";
    import { privateKeyToAccount } from "viem/accounts";
    import { tempoTestnet } from "viem/chains";
    
    const client = createClient({
      account: privateKeyToAccount("0x…"),
      chain: tempoTestnet.extend({
        feeToken: "0x20c00000000000000000000000000000000000fa",
      }),
      transport: http(),
    });
    
    const receipt = client.sendTransactionSync({
      calls: [
        { data: "0x…", to: "0x…" },
        { data: "0x…", to: "0x…" },
        { data: "0x…", to: "0x…" },
      ],
      feePayer: privateKeyToAccount("0x…"),
    });

    You can also use Tempo Actions to call to enshrined protocol features like the Stablecoin Token Factory:

    import { createClient, http } from "viem";
    import { privateKeyToAccount } from "viem/accounts";
    import { tempoTestnet } from "viem/chains";
    import { tempoActions } from "viem/tempo";
    
    const client = createClient({
      account: privateKeyToAccount("0x…"),
      chain: tempoTestnet,
      transport: http(),
    }).extend(tempoActions());
    
    const { receipt, token } = await client.token.createSync({
      currency: "USD",
      name: "My Company USD",
      symbol: "CUSD",
    });

Patch Changes

[email protected]

15 Dec 05:26
e9b8de9

Choose a tag to compare

Patch Changes

[email protected]

14 Dec 04:28
43e6234

Choose a tag to compare

Minor Changes

  • #4134 d9d666beeccf748157d1292849f5a0d18768baf7 Thanks @mikelxc! - Added EntryPoint v0.9 support for Account Abstraction (ERC-4337).

    • Added entryPoint09Abi and entryPoint09Address constants
    • Added '0.9' to EntryPointVersion type
    • Added UserOperation<'0.9'> with new paymasterSignature field for parallelizable paymaster signing
    • Updated getUserOperationHash to support v0.9 (uses EIP-712 typed data like v0.8)
    • Updated toPackedUserOperation to handle paymasterSignature
    • Updated prepareUserOperation type definitions for v0.9

Patch Changes

[email protected]

03 Dec 03:05
684f28f

Choose a tag to compare

Patch Changes

[email protected]

03 Dec 02:12
0107198

Choose a tag to compare

Minor Changes

Patch Changes

[email protected]

02 Dec 20:49
74a2910

Choose a tag to compare

Patch Changes

[email protected]

25 Nov 22:18
8c7ec82

Choose a tag to compare

Patch Changes