Migration from zksync-web3
zksync-web3
Migration from Note on v5 and v6
This migration notes apply to zksync-ethers v6
.
If you're using v5, you don't need to do any changes in your code as zksync-ethers v5
uses ethers v5
similar to the deprecated zksync-web3
.
This guide provides some high-level differences between zksync-web3
/zksync-ethers v5
and zksync-ethers v6
for those who are familiar with zksync-web3
and need a quick primer. zksync-ethers v6
has several differences since it's using ethers.js v6
, compared to zksync-web3
, which uses ethers.js v5
. Before continuing to get to know the changes made in zksync-ethers
, you should read the migration guide from ethers.js v5
to ethers.js v6
.
Differences:
Token.Address
has been removed because it was deprecated.Provider.getMessageProof
has been removed because it was deprecated.Provider.getTokenPrice
has been removed because it was deprecated.Provider.getBlockWithTransaction
has been replaced withProvider.getBlock(<BlockTag>, true)
.BlockWithTransaction
has been removed.TransactionRequest.calldata
has been changed fromBytesLike
tostring
.transaction.calldata
parameter inProvider.estimateL1ToL2Execute
has been changed fromBytesLike
tostring
.transaction.calldata
parameter inAdaterL1.getRequestExecuteTx
has been changed fromBytesLike
tostring
.transaction.calldata
parameter inAdapterL1.estimateGasRequestExecute
has been changed fromBytesLike
tostring
.transaction.calldata
parameter inAdapterL1.RequestExecute
has been changed fromBytesLike
tostring
.utils.parseTransaction
has been replaced byutils.parseEip712
.