Skip to content

Commit

Permalink
Add Arbitrum network id
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanchambras committed Jun 7, 2024
1 parent 7d7b3c4 commit f0c1f6c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/utils/ChainId.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ class ChainId {
mainnet: i32 = 1
goerli: i32 = 5
sepolia: i32 = 11155111
arbitrum: i32 = 42161
}

const chainId = new ChainId()
Expand All @@ -13,6 +14,8 @@ export function getChainId(network: string): i32 {
return chainId.goerli
} else if (network == "sepolia") {
return chainId.sepolia
} else if (network == "arbitrum-one") {
return chainId.arbitrum
}
return chainId.mainnet
throw new Error("Unsupported network")
}

0 comments on commit f0c1f6c

Please sign in to comment.