Home
Hardhat plugins for zkSync 2.0
JS Web3 SDK
  • JS Web3 SDK
  • Getting started
  • Providers
  • Accounts: overview
  • Accounts: L1->L2 transactions
  • Contracts
  • zkSync features
  • Utilities
  • Types
  • Front-end integration
  • Home
  • /
  • JS Web3 SDK
  • /
  • Contracts

Contracts

zksync-web3 does not implement any new Contract class, since ethers.Contract fully works out of the box. However, for convenience, the library still re-exports this class.

Since deploying smart contracts on zkSync has some differences from deploying on Ethereum, there is a need for a specific ContractFactory method. It supports the same interface as ethers.ContractFactory.

In order to pay for smart contract interactions in ERC20 tokens, customData override should be used. You can read more about accessing zkSync features in the next chaper.

Last updated: 8/23/2022, 9:04:05 AM
Previous
Accounts: L1->L2 transactions
Next
zkSync features
Edit on GitHub