@wagmi/core 0.0.0-20220909032847

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +30 -0
  3. package/chains/dist/wagmi-core-chains.esm.d.ts +11 -0
  4. package/chains/dist/wagmi-core-chains.esm.js +2 -0
  5. package/chains/package.json +3 -0
  6. package/connectors/coinbaseWallet/dist/wagmi-core-connectors-coinbaseWallet.esm.d.ts +11 -0
  7. package/connectors/coinbaseWallet/dist/wagmi-core-connectors-coinbaseWallet.esm.js +246 -0
  8. package/connectors/coinbaseWallet/package.json +3 -0
  9. package/connectors/metaMask/dist/wagmi-core-connectors-metaMask.esm.d.ts +11 -0
  10. package/connectors/metaMask/dist/wagmi-core-connectors-metaMask.esm.js +146 -0
  11. package/connectors/metaMask/package.json +3 -0
  12. package/connectors/mock/dist/wagmi-core-connectors-mock.esm.d.ts +11 -0
  13. package/connectors/mock/dist/wagmi-core-connectors-mock.esm.js +257 -0
  14. package/connectors/mock/package.json +3 -0
  15. package/connectors/walletConnect/dist/wagmi-core-connectors-walletConnect.esm.d.ts +11 -0
  16. package/connectors/walletConnect/dist/wagmi-core-connectors-walletConnect.esm.js +207 -0
  17. package/connectors/walletConnect/package.json +3 -0
  18. package/dist/chains-de91362e.esm.js +493 -0
  19. package/dist/getProvider-34b63ce9.esm.js +1055 -0
  20. package/dist/rpcs-f39d022b.esm.js +50 -0
  21. package/dist/wagmi-core.esm.d.ts +11 -0
  22. package/dist/wagmi-core.esm.js +1515 -0
  23. package/package.json +76 -0
  24. package/providers/alchemy/dist/wagmi-core-providers-alchemy.esm.d.ts +11 -0
  25. package/providers/alchemy/dist/wagmi-core-providers-alchemy.esm.js +32 -0
  26. package/providers/alchemy/package.json +3 -0
  27. package/providers/infura/dist/wagmi-core-providers-infura.esm.d.ts +11 -0
  28. package/providers/infura/dist/wagmi-core-providers-infura.esm.js +32 -0
  29. package/providers/infura/package.json +3 -0
  30. package/providers/jsonRpc/dist/wagmi-core-providers-jsonRpc.esm.d.ts +11 -0
  31. package/providers/jsonRpc/dist/wagmi-core-providers-jsonRpc.esm.js +42 -0
  32. package/providers/jsonRpc/package.json +3 -0
  33. package/providers/public/dist/wagmi-core-providers-public.esm.d.ts +11 -0
  34. package/providers/public/dist/wagmi-core-providers-public.esm.js +28 -0
  35. package/providers/public/package.json +3 -0
@@ -0,0 +1,493 @@
1
+ import { a as alchemyRpcUrls, p as publicRpcUrls, i as infuraRpcUrls } from './rpcs-f39d022b.esm.js';
2
+
3
+ const etherscanBlockExplorers = {
4
+ mainnet: {
5
+ name: 'Etherscan',
6
+ url: 'https://etherscan.io'
7
+ },
8
+ ropsten: {
9
+ name: 'Etherscan',
10
+ url: 'https://ropsten.etherscan.io'
11
+ },
12
+ rinkeby: {
13
+ name: 'Etherscan',
14
+ url: 'https://rinkeby.etherscan.io'
15
+ },
16
+ goerli: {
17
+ name: 'Etherscan',
18
+ url: 'https://goerli.etherscan.io'
19
+ },
20
+ kovan: {
21
+ name: 'Etherscan',
22
+ url: 'https://kovan.etherscan.io'
23
+ },
24
+ sepolia: {
25
+ name: 'Etherscan',
26
+ url: 'https://sepolia.etherscan.io'
27
+ },
28
+ optimism: {
29
+ name: 'Etherscan',
30
+ url: 'https://optimistic.etherscan.io'
31
+ },
32
+ optimismKovan: {
33
+ name: 'Etherscan',
34
+ url: 'https://kovan-optimistic.etherscan.io'
35
+ },
36
+ polygon: {
37
+ name: 'PolygonScan',
38
+ url: 'https://polygonscan.com'
39
+ },
40
+ polygonMumbai: {
41
+ name: 'PolygonScan',
42
+ url: 'https://mumbai.polygonscan.com'
43
+ },
44
+ arbitrum: {
45
+ name: 'Arbiscan',
46
+ url: 'https://arbiscan.io'
47
+ },
48
+ arbitrumRinkeby: {
49
+ name: 'Arbiscan',
50
+ url: 'https://testnet.arbiscan.io'
51
+ }
52
+ };
53
+
54
+ const chainId = {
55
+ mainnet: 1,
56
+ ropsten: 3,
57
+ rinkeby: 4,
58
+ goerli: 5,
59
+ kovan: 42,
60
+ sepolia: 11155111,
61
+ optimism: 10,
62
+ optimismKovan: 69,
63
+ optimismGoerli: 420,
64
+ polygon: 137,
65
+ polygonMumbai: 80001,
66
+ arbitrum: 42161,
67
+ arbitrumRinkeby: 421611,
68
+ arbitrumGoerli: 421613,
69
+ localhost: 1337,
70
+ hardhat: 31337,
71
+ foundry: 31337
72
+ };
73
+ const mainnet = {
74
+ id: chainId.mainnet,
75
+ name: 'Ethereum',
76
+ network: 'homestead',
77
+ nativeCurrency: {
78
+ name: 'Ether',
79
+ symbol: 'ETH',
80
+ decimals: 18
81
+ },
82
+ rpcUrls: {
83
+ alchemy: alchemyRpcUrls.mainnet,
84
+ default: publicRpcUrls.mainnet,
85
+ infura: infuraRpcUrls.mainnet,
86
+ public: publicRpcUrls.mainnet
87
+ },
88
+ blockExplorers: {
89
+ etherscan: etherscanBlockExplorers.mainnet,
90
+ default: etherscanBlockExplorers.mainnet
91
+ },
92
+ ens: {
93
+ address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e'
94
+ },
95
+ multicall: {
96
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
97
+ blockCreated: 14353601
98
+ }
99
+ };
100
+ const ropsten = {
101
+ id: chainId.ropsten,
102
+ name: 'Ropsten',
103
+ network: 'ropsten',
104
+ nativeCurrency: {
105
+ name: 'Ropsten Ether',
106
+ symbol: 'ETH',
107
+ decimals: 18
108
+ },
109
+ rpcUrls: {
110
+ alchemy: alchemyRpcUrls.ropsten,
111
+ default: publicRpcUrls.ropsten,
112
+ infura: infuraRpcUrls.ropsten,
113
+ public: publicRpcUrls.ropsten
114
+ },
115
+ blockExplorers: {
116
+ etherscan: etherscanBlockExplorers.ropsten,
117
+ default: etherscanBlockExplorers.ropsten
118
+ },
119
+ ens: {
120
+ address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e'
121
+ },
122
+ multicall: {
123
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
124
+ blockCreated: 12063863
125
+ },
126
+ testnet: true
127
+ };
128
+ const rinkeby = {
129
+ id: chainId.rinkeby,
130
+ name: 'Rinkeby',
131
+ network: 'rinkeby',
132
+ nativeCurrency: {
133
+ name: 'Rinkeby Ether',
134
+ symbol: 'ETH',
135
+ decimals: 18
136
+ },
137
+ rpcUrls: {
138
+ alchemy: alchemyRpcUrls.rinkeby,
139
+ default: publicRpcUrls.rinkeby,
140
+ infura: infuraRpcUrls.rinkeby,
141
+ public: publicRpcUrls.rinkeby
142
+ },
143
+ blockExplorers: {
144
+ etherscan: etherscanBlockExplorers.rinkeby,
145
+ default: etherscanBlockExplorers.rinkeby
146
+ },
147
+ ens: {
148
+ address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e'
149
+ },
150
+ multicall: {
151
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
152
+ blockCreated: 10299530
153
+ },
154
+ testnet: true
155
+ };
156
+ const goerli = {
157
+ id: chainId.goerli,
158
+ name: 'Goerli',
159
+ network: 'goerli',
160
+ nativeCurrency: {
161
+ name: 'Goerli Ether',
162
+ symbol: 'ETH',
163
+ decimals: 18
164
+ },
165
+ rpcUrls: {
166
+ alchemy: alchemyRpcUrls.goerli,
167
+ default: publicRpcUrls.goerli,
168
+ infura: infuraRpcUrls.goerli,
169
+ public: publicRpcUrls.goerli
170
+ },
171
+ blockExplorers: {
172
+ etherscan: etherscanBlockExplorers.goerli,
173
+ default: etherscanBlockExplorers.goerli
174
+ },
175
+ ens: {
176
+ address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e'
177
+ },
178
+ multicall: {
179
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
180
+ blockCreated: 6507670
181
+ },
182
+ testnet: true
183
+ };
184
+ const kovan = {
185
+ id: chainId.kovan,
186
+ name: 'Kovan',
187
+ network: 'kovan',
188
+ nativeCurrency: {
189
+ name: 'Kovan Ether',
190
+ symbol: 'ETH',
191
+ decimals: 18
192
+ },
193
+ rpcUrls: {
194
+ alchemy: alchemyRpcUrls.kovan,
195
+ default: publicRpcUrls.kovan,
196
+ infura: infuraRpcUrls.kovan,
197
+ public: publicRpcUrls.kovan
198
+ },
199
+ blockExplorers: {
200
+ etherscan: etherscanBlockExplorers.kovan,
201
+ default: etherscanBlockExplorers.kovan
202
+ },
203
+ multicall: {
204
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
205
+ blockCreated: 30285908
206
+ },
207
+ testnet: true
208
+ };
209
+ const sepolia = {
210
+ id: chainId.sepolia,
211
+ name: 'Sepolia',
212
+ network: 'sepolia',
213
+ nativeCurrency: {
214
+ name: 'Sepolia Ether',
215
+ symbol: 'ETH',
216
+ decimals: 18
217
+ },
218
+ rpcUrls: {
219
+ default: publicRpcUrls.sepolia,
220
+ public: publicRpcUrls.sepolia
221
+ },
222
+ blockExplorers: {
223
+ etherscan: etherscanBlockExplorers.sepolia,
224
+ default: etherscanBlockExplorers.sepolia
225
+ },
226
+ multicall: {
227
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
228
+ blockCreated: 751532
229
+ },
230
+ testnet: true
231
+ };
232
+ const optimism = {
233
+ id: chainId.optimism,
234
+ name: 'Optimism',
235
+ network: 'optimism',
236
+ nativeCurrency: {
237
+ name: 'Ether',
238
+ symbol: 'ETH',
239
+ decimals: 18
240
+ },
241
+ rpcUrls: {
242
+ alchemy: alchemyRpcUrls.optimism,
243
+ default: publicRpcUrls.optimism,
244
+ infura: infuraRpcUrls.optimism,
245
+ public: publicRpcUrls.optimism
246
+ },
247
+ blockExplorers: {
248
+ etherscan: etherscanBlockExplorers.optimism,
249
+ default: etherscanBlockExplorers.optimism
250
+ },
251
+ multicall: {
252
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
253
+ blockCreated: 4286263
254
+ }
255
+ };
256
+ const optimismKovan = {
257
+ id: chainId.optimismKovan,
258
+ name: 'Optimism Kovan',
259
+ network: 'optimism-kovan',
260
+ nativeCurrency: {
261
+ name: 'Kovan Ether',
262
+ symbol: 'ETH',
263
+ decimals: 18
264
+ },
265
+ rpcUrls: {
266
+ alchemy: alchemyRpcUrls.optimismKovan,
267
+ default: publicRpcUrls.optimismKovan,
268
+ infura: infuraRpcUrls.optimismKovan,
269
+ public: publicRpcUrls.optimismKovan
270
+ },
271
+ blockExplorers: {
272
+ etherscan: etherscanBlockExplorers.optimismKovan,
273
+ default: etherscanBlockExplorers.optimismKovan
274
+ },
275
+ multicall: {
276
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
277
+ blockCreated: 1418387
278
+ },
279
+ testnet: true
280
+ };
281
+ const optimismGoerli = {
282
+ id: chainId.optimismGoerli,
283
+ name: 'Optimism Goerli',
284
+ network: 'optimism-goerli',
285
+ nativeCurrency: {
286
+ name: 'Goerli Ether',
287
+ symbol: 'ETH',
288
+ decimals: 18
289
+ },
290
+ rpcUrls: {
291
+ alchemy: alchemyRpcUrls.optimismGoerli,
292
+ default: publicRpcUrls.optimismGoerli,
293
+ infura: infuraRpcUrls.optimismGoerli,
294
+ public: publicRpcUrls.optimismGoerli
295
+ },
296
+ blockExplorers: {
297
+ default: {
298
+ name: 'Blockscout',
299
+ url: 'https://blockscout.com/optimism/goerli'
300
+ }
301
+ },
302
+ multicall: {
303
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
304
+ blockCreated: 49461
305
+ },
306
+ testnet: true
307
+ };
308
+ const polygon = {
309
+ id: chainId.polygon,
310
+ name: 'Polygon',
311
+ network: 'matic',
312
+ nativeCurrency: {
313
+ name: 'MATIC',
314
+ symbol: 'MATIC',
315
+ decimals: 18
316
+ },
317
+ rpcUrls: {
318
+ alchemy: alchemyRpcUrls.polygon,
319
+ default: publicRpcUrls.polygon,
320
+ infura: infuraRpcUrls.polygon,
321
+ public: publicRpcUrls.polygon
322
+ },
323
+ blockExplorers: {
324
+ etherscan: etherscanBlockExplorers.polygon,
325
+ default: etherscanBlockExplorers.polygon
326
+ },
327
+ multicall: {
328
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
329
+ blockCreated: 25770160
330
+ }
331
+ };
332
+ const polygonMumbai = {
333
+ id: chainId.polygonMumbai,
334
+ name: 'Polygon Mumbai',
335
+ network: 'maticmum',
336
+ nativeCurrency: {
337
+ name: 'MATIC',
338
+ symbol: 'MATIC',
339
+ decimals: 18
340
+ },
341
+ rpcUrls: {
342
+ alchemy: alchemyRpcUrls.polygonMumbai,
343
+ default: publicRpcUrls.polygonMumbai,
344
+ infura: infuraRpcUrls.polygonMumbai,
345
+ public: publicRpcUrls.polygonMumbai
346
+ },
347
+ blockExplorers: {
348
+ etherscan: etherscanBlockExplorers.polygonMumbai,
349
+ default: etherscanBlockExplorers.polygonMumbai
350
+ },
351
+ multicall: {
352
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
353
+ blockCreated: 25444704
354
+ },
355
+ testnet: true
356
+ };
357
+ const arbitrum = {
358
+ id: chainId.arbitrum,
359
+ name: 'Arbitrum One',
360
+ network: 'arbitrum',
361
+ nativeCurrency: {
362
+ name: 'Ether',
363
+ symbol: 'ETH',
364
+ decimals: 18
365
+ },
366
+ rpcUrls: {
367
+ alchemy: alchemyRpcUrls.arbitrum,
368
+ default: publicRpcUrls.arbitrum,
369
+ infura: infuraRpcUrls.arbitrum,
370
+ public: publicRpcUrls.arbitrum
371
+ },
372
+ blockExplorers: {
373
+ arbitrum: {
374
+ name: 'Arbitrum Explorer',
375
+ url: 'https://explorer.arbitrum.io'
376
+ },
377
+ etherscan: etherscanBlockExplorers.arbitrum,
378
+ default: etherscanBlockExplorers.arbitrum
379
+ },
380
+ multicall: {
381
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
382
+ blockCreated: 7654707
383
+ }
384
+ };
385
+ const arbitrumRinkeby = {
386
+ id: chainId.arbitrumRinkeby,
387
+ name: 'Arbitrum Rinkeby',
388
+ network: 'arbitrum-rinkeby',
389
+ nativeCurrency: {
390
+ name: 'Arbitrum Rinkeby Ether',
391
+ symbol: 'ETH',
392
+ decimals: 18
393
+ },
394
+ rpcUrls: {
395
+ alchemy: alchemyRpcUrls.arbitrumRinkeby,
396
+ default: publicRpcUrls.arbitrumRinkeby,
397
+ infura: infuraRpcUrls.arbitrumRinkeby,
398
+ public: publicRpcUrls.arbitrumRinkeby
399
+ },
400
+ blockExplorers: {
401
+ arbitrum: {
402
+ name: 'Arbitrum Explorer',
403
+ url: 'https://rinkeby-explorer.arbitrum.io'
404
+ },
405
+ etherscan: etherscanBlockExplorers.arbitrumRinkeby,
406
+ default: etherscanBlockExplorers.arbitrumRinkeby
407
+ },
408
+ multicall: {
409
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
410
+ blockCreated: 10228837
411
+ },
412
+ testnet: true
413
+ };
414
+ const arbitrumGoerli = {
415
+ id: chainId.arbitrumGoerli,
416
+ name: 'Arbitrum Goerli',
417
+ network: 'arbitrum-goerli',
418
+ nativeCurrency: {
419
+ name: 'Arbitrum Goerli Ether',
420
+ symbol: 'ETH',
421
+ decimals: 18
422
+ },
423
+ rpcUrls: {
424
+ alchemy: alchemyRpcUrls.arbitrumGoerli,
425
+ default: publicRpcUrls.arbitrumGoerli,
426
+ infura: infuraRpcUrls.arbitrumGoerli,
427
+ public: publicRpcUrls.arbitrumGoerli
428
+ },
429
+ blockExplorers: {
430
+ default: {
431
+ name: 'Arbitrum Explorer',
432
+ url: 'https://goerli-rollup-explorer.arbitrum.io'
433
+ }
434
+ },
435
+ multicall: {
436
+ address: '0xca11bde05977b3631167028862be2a173976ca11',
437
+ blockCreated: 88114
438
+ },
439
+ testnet: true
440
+ };
441
+ const localhost = {
442
+ id: chainId.localhost,
443
+ name: 'Localhost',
444
+ network: 'localhost',
445
+ rpcUrls: {
446
+ default: 'http://127.0.0.1:8545'
447
+ }
448
+ };
449
+ const hardhat = {
450
+ id: chainId.hardhat,
451
+ name: 'Hardhat',
452
+ network: 'hardhat',
453
+ rpcUrls: {
454
+ default: 'http://127.0.0.1:8545'
455
+ }
456
+ };
457
+ const foundry = {
458
+ id: chainId.foundry,
459
+ name: 'Foundry',
460
+ network: 'foundry',
461
+ rpcUrls: {
462
+ default: 'http://127.0.0.1:8545'
463
+ }
464
+ };
465
+ /**
466
+ * Common chains for convenience
467
+ * Should not contain all possible chains
468
+ */
469
+
470
+ const chain = {
471
+ mainnet,
472
+ ropsten,
473
+ rinkeby,
474
+ goerli,
475
+ kovan,
476
+ sepolia,
477
+ optimism,
478
+ optimismGoerli,
479
+ optimismKovan,
480
+ polygon,
481
+ polygonMumbai,
482
+ arbitrum,
483
+ arbitrumGoerli,
484
+ arbitrumRinkeby,
485
+ localhost,
486
+ hardhat,
487
+ foundry
488
+ };
489
+ const allChains = [mainnet, ropsten, rinkeby, goerli, kovan, sepolia, optimism, optimismKovan, optimismGoerli, polygon, polygonMumbai, arbitrum, arbitrumGoerli, arbitrumRinkeby, localhost, hardhat, foundry];
490
+ const defaultChains = [mainnet, ropsten, rinkeby, goerli, kovan];
491
+ const defaultL2Chains = [arbitrum, arbitrumRinkeby, arbitrumGoerli, optimism, optimismKovan, optimismGoerli];
492
+
493
+ export { allChains as a, chainId as b, chain as c, defaultChains as d, defaultL2Chains as e, etherscanBlockExplorers as f, arbitrum as g, arbitrumGoerli as h, arbitrumRinkeby as i, foundry as j, goerli as k, hardhat as l, mainnet as m, kovan as n, localhost as o, optimism as p, optimismKovan as q, optimismGoerli as r, sepolia as s, polygon as t, polygonMumbai as u, rinkeby as v, ropsten as w };