hardhat.config.ts 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. import "@matterlabs/hardhat-zksync-deploy";
  2. import "@matterlabs/hardhat-zksync-solc";
  3. import "@nomiclabs/hardhat-etherscan";
  4. import "@openzeppelin/hardhat-upgrades";
  5. import "@matterlabs/hardhat-zksync-verify";
  6. module.exports = {
  7. zksolc: {
  8. version: "1.3.1",
  9. compilerSource: "binary",
  10. settings: {
  11. optimizer: {
  12. enabled: true,
  13. },
  14. },
  15. },
  16. defaultNetwork: "zkSyncTestnet",
  17. networks: {
  18. goerli: {
  19. url: `https://goerli.infura.io/v3/${process.env.INFURA_KEY}`,
  20. zksync: false,
  21. },
  22. zkSyncTestnet: {
  23. url: "https://zksync2-testnet.zksync.dev", // URL of the zkSync network RPC
  24. ethNetwork: "goerli", // Can also be the RPC URL of the Ethereum network (e.g. `https://goerli.infura.io/v3/<API_KEY>`)
  25. zksync: true,
  26. chainId: 280,
  27. verifyURL:
  28. "https://zksync2-testnet-explorer.zksync.dev/contract_verification",
  29. },
  30. zkSyncMainnet: {
  31. url: "https://zksync2-mainnet.zksync.io",
  32. ethNetwork: "mainnet",
  33. zksync: true,
  34. chainId: 324,
  35. verifyURL:
  36. "https://zksync2-mainnet-explorer.zksync.io/contract_verification",
  37. },
  38. },
  39. solidity: {
  40. version: "0.8.4",
  41. settings: {
  42. optimizer: {
  43. enabled: true,
  44. runs: 10000,
  45. },
  46. },
  47. },
  48. };