From d4460ab78f6bce03f8c0f6a5e823a61cec8c5cb3 Mon Sep 17 00:00:00 2001 From: jxom Date: Sat, 15 Jul 2023 16:08:08 +0200 Subject: [PATCH] feat: add base (#426) * feat: add base * chore changeset --- .changeset/eighty-chicken-smash.md | 5 +++++ packages/chains/README.md | 1 + packages/chains/src/base.ts | 36 ++++++++++++++++++++++++++++++ packages/chains/src/index.ts | 1 + 4 files changed, 43 insertions(+) create mode 100644 .changeset/eighty-chicken-smash.md create mode 100644 packages/chains/src/base.ts diff --git a/.changeset/eighty-chicken-smash.md b/.changeset/eighty-chicken-smash.md new file mode 100644 index 00000000..235731f1 --- /dev/null +++ b/.changeset/eighty-chicken-smash.md @@ -0,0 +1,5 @@ +--- +"@wagmi/chains": minor +--- + +Added Base diff --git a/packages/chains/README.md b/packages/chains/README.md index 543fd989..8ae3eb02 100644 --- a/packages/chains/README.md +++ b/packages/chains/README.md @@ -35,6 +35,7 @@ const { chains, provider } = configureChains( - `auroraTestnet` - `avalanche` - `avalancheFuji` +- `base` - `baseGoerli` - `bronos` - `bronosTestnet` diff --git a/packages/chains/src/base.ts b/packages/chains/src/base.ts new file mode 100644 index 00000000..0e885829 --- /dev/null +++ b/packages/chains/src/base.ts @@ -0,0 +1,36 @@ +import { Chain } from './types' + +export const base = { + id: 8453, + network: 'base', + name: 'Base', + nativeCurrency: { name: 'Base', symbol: 'ETH', decimals: 18 }, + rpcUrls: { + default: { + http: ['https://developer-access-mainnet.base.org'], + }, + public: { + http: ['https://developer-access-mainnet.base.org'], + }, + }, + blockExplorers: { + blockscout: { + name: 'Basescout', + url: 'https://base.blockscout.com', + }, + default: { + name: 'Basescan', + url: 'https://basescan.org', + }, + etherscan: { + name: 'Basescan', + url: 'https://basescan.org', + }, + }, + contracts: { + multicall3: { + address: '0xca11bde05977b3631167028862be2a173976ca11', + blockCreated: 5022, + }, + }, +} as const satisfies Chain diff --git a/packages/chains/src/index.ts b/packages/chains/src/index.ts index 537632f5..2663fb28 100644 --- a/packages/chains/src/index.ts +++ b/packages/chains/src/index.ts @@ -7,6 +7,7 @@ export { aurora } from './aurora' export { auroraTestnet } from './auroraTestnet' export { avalanche } from './avalanche' export { avalancheFuji } from './avalancheFuji' +export { base } from './base' export { baseGoerli } from './baseGoerli' export { bearNetworkChainMainnet } from './bearNetworkChainMainnet' export { bearNetworkChainTestnet } from './bearNetworkChainTestnet'