From 4f514c652381c4f09d22037bc34d61663e08dc77 Mon Sep 17 00:00:00 2001 From: Istora Mandiri <1696942+IstoraMandiri@users.noreply.github.com> Date: Wed, 9 Aug 2023 11:16:41 +0700 Subject: [PATCH] feat: add Ethereum Classic chain (#466) * Added Ethereum Classic chain * Add Classic to readme * Fix classic blockscout explorer name * Update classic.ts --------- Co-authored-by: jxom --- .changeset/quick-queens-protect.md | 5 +++++ packages/chains/README.md | 1 + packages/chains/src/classic.ts | 22 ++++++++++++++++++++++ packages/chains/src/index.ts | 1 + 4 files changed, 29 insertions(+) create mode 100644 .changeset/quick-queens-protect.md create mode 100644 packages/chains/src/classic.ts diff --git a/.changeset/quick-queens-protect.md b/.changeset/quick-queens-protect.md new file mode 100644 index 00000000..608e5684 --- /dev/null +++ b/.changeset/quick-queens-protect.md @@ -0,0 +1,5 @@ +--- +"@wagmi/chains": minor +--- + +Added Ethereum Classic Chain diff --git a/packages/chains/README.md b/packages/chains/README.md index 8586e64a..4baaa12e 100644 --- a/packages/chains/README.md +++ b/packages/chains/README.md @@ -45,6 +45,7 @@ const { chains, provider } = configureChains( - `celo` - `celoAlfajores` - `celoCannoli` +- `classic` - `cronos` - `cronosTestnet` - `edgeware` diff --git a/packages/chains/src/classic.ts b/packages/chains/src/classic.ts new file mode 100644 index 00000000..0677a059 --- /dev/null +++ b/packages/chains/src/classic.ts @@ -0,0 +1,22 @@ +import { Chain } from './types' + +export const classic = { + id: 61, + name: 'Ethereum Classic', + network: 'classic', + nativeCurrency: { + decimals: 18, + name: 'ETC', + symbol: 'ETC', + }, + rpcUrls: { + default: { http: ['https://etc.rivet.link'] }, + public: { http: ['https://etc.rivet.link'] }, + }, + blockExplorers: { + default: { + name: 'Blockscout', + url: 'https://blockscout.com/etc/mainnet', + }, + }, +} as const satisfies Chain diff --git a/packages/chains/src/index.ts b/packages/chains/src/index.ts index 1969645c..ff92204b 100644 --- a/packages/chains/src/index.ts +++ b/packages/chains/src/index.ts @@ -22,6 +22,7 @@ export { canto } from './canto' export { celo } from './celo' export { celoAlfajores } from './celoAlfajores' export { celoCannoli } from './celoCannoli' +export { classic } from './classic' export { confluxESpace } from './confluxESpace' export { cronos } from './cronos' export { cronosTestnet } from './cronosTestnet'