-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathhardhat.config.ts
91 lines (88 loc) · 2.35 KB
/
hardhat.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
import { HardhatUserConfig } from "hardhat/config";
import "@nomicfoundation/hardhat-toolbox";
import "@nomicfoundation/hardhat-foundry";
import "@nomicfoundation/hardhat-verify";
import "solidity-docgen";
// load .env file
import { config as dotEnvConfig } from "dotenv";
dotEnvConfig();
const config: HardhatUserConfig = {
solidity: {
version: "0.8.27",
settings: {
evmVersion: 'cancun',
optimizer: {
enabled: true,
runs: 200
}
}
},
docgen: require("./docs/config"),
networks: {
hardhat: {
},
anvil: {
chainId: 1337,
url: process.env.NETWORK_URL || "http://anvil:7545",
accounts: {
mnemonic: "candy maple cake sugar pudding cream honey rich smooth crumble sweet treat",
count: 20,
},
},
polygonAmoy: {
chainId: 80002,
url: process.env.NETWORK_URL || 'https://rpc-amoy.polygon.technology/',
gasPrice: 30000000000,
// maxFeePerGas: 30000000000,
accounts: {
mnemonic: process.env.WALLET_MNEMONIC || "candy maple cake sugar pudding cream honey rich smooth crumble sweet treat",
count: 20,
},
},
mainnet: {
chainId: 1,
url: process.env.NETWORK_URL || 'https://mainnet.infura.io/v3/' + process.env.WEB3_INFURA_PROJECT_ID,
},
baseSepolia: {
chainId: 84532,
url: process.env.NETWORK_URL || "https://sepolia.base.org",
accounts: {
mnemonic: process.env.WALLET_MNEMONIC || "candy maple cake sugar pudding cream honey rich smooth crumble sweet treat",
count: 20,
},
},
base: {
chainId: 8453,
url: process.env.NETWORK_URL || "https://mainnet.base.org",
accounts: {
mnemonic: process.env.WALLET_MNEMONIC || "",
count: 20,
},
},
},
etherscan: {
apiKey: {
polygonAmoy: process.env.POLYGONSCAN_API_KEY || "",
base: process.env.BASESCAN_API_KEY || "",
},
customChains: [
{
network: "polygonAmoy",
chainId: 80002,
urls: {
apiURL: "https://api-amoy.polygonscan.com/api",
browserURL: "https://amoy.polygonscan.com"
},
},
{
network: "base",
chainId: 8453,
urls: {
apiURL: "https://api.basescan.org/api",
browserURL: "https://basescan.org/"
},
}
]
},
};
export default config;