Skip to content

Commit

Permalink
fix(example-next): update urls for passing type checking (Uniswap#605)
Browse files Browse the repository at this point in the history
Co-authored-by: Noah Zinsmeister <[email protected]>
  • Loading branch information
makbari and NoahZinsmeister authored Jul 11, 2022
1 parent c7123af commit b1786d3
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions packages/example-next/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,87 +46,87 @@ export function getAddChainParameters(chainId: number): AddEthereumChainParamete
export const CHAINS: { [chainId: number]: BasicChainInformation | ExtendedChainInformation } = {
1: {
urls: [
process.env.infuraKey ? `https://mainnet.infura.io/v3/${process.env.infuraKey}` : undefined,
process.env.alchemyKey ? `https://eth-mainnet.alchemyapi.io/v2/${process.env.alchemyKey}` : undefined,
process.env.infuraKey ? `https://mainnet.infura.io/v3/${process.env.infuraKey}` : '',
process.env.alchemyKey ? `https://eth-mainnet.alchemyapi.io/v2/${process.env.alchemyKey}` : '',
'https://cloudflare-eth.com',
].filter((url) => url !== undefined),
].filter((url) => url !== ''),
name: 'Mainnet',
},
3: {
urls: [process.env.infuraKey ? `https://ropsten.infura.io/v3/${process.env.infuraKey}` : undefined].filter(
(url) => url !== undefined
urls: [process.env.infuraKey ? `https://ropsten.infura.io/v3/${process.env.infuraKey}` : ''].filter(
(url) => url !== ''
),
name: 'Ropsten',
},
4: {
urls: [process.env.infuraKey ? `https://rinkeby.infura.io/v3/${process.env.infuraKey}` : undefined].filter(
(url) => url !== undefined
urls: [process.env.infuraKey ? `https://rinkeby.infura.io/v3/${process.env.infuraKey}` : ''].filter(
(url) => url !== ''
),
name: 'Rinkeby',
},
5: {
urls: [process.env.infuraKey ? `https://goerli.infura.io/v3/${process.env.infuraKey}` : undefined].filter(
(url) => url !== undefined
urls: [process.env.infuraKey ? `https://goerli.infura.io/v3/${process.env.infuraKey}` : ''].filter(
(url) => url !== ''
),
name: 'Görli',
},
42: {
urls: [process.env.infuraKey ? `https://kovan.infura.io/v3/${process.env.infuraKey}` : undefined].filter(
(url) => url !== undefined
urls: [process.env.infuraKey ? `https://kovan.infura.io/v3/${process.env.infuraKey}` : ''].filter(
(url) => url !== ''
),
name: 'Kovan',
},
// Optimism
10: {
urls: [
process.env.infuraKey ? `https://optimism-mainnet.infura.io/v3/${process.env.infuraKey}` : undefined,
process.env.infuraKey ? `https://optimism-mainnet.infura.io/v3/${process.env.infuraKey}` : '',
'https://mainnet.optimism.io',
].filter((url) => url !== undefined),
].filter((url) => url !== ''),
name: 'Optimism',
nativeCurrency: ETH,
blockExplorerUrls: ['https://optimistic.etherscan.io'],
},
69: {
urls: [
process.env.infuraKey ? `https://optimism-kovan.infura.io/v3/${process.env.infuraKey}` : undefined,
process.env.infuraKey ? `https://optimism-kovan.infura.io/v3/${process.env.infuraKey}` : '',
'https://kovan.optimism.io',
].filter((url) => url !== undefined),
].filter((url) => url !== ''),
name: 'Optimism Kovan',
nativeCurrency: ETH,
blockExplorerUrls: ['https://kovan-optimistic.etherscan.io'],
},
// Arbitrum
42161: {
urls: [
process.env.infuraKey ? `https://arbitrum-mainnet.infura.io/v3/${process.env.infuraKey}` : undefined,
process.env.infuraKey ? `https://arbitrum-mainnet.infura.io/v3/${process.env.infuraKey}` : '',
'https://arb1.arbitrum.io/rpc',
].filter((url) => url !== undefined),
].filter((url) => url !== ''),
name: 'Arbitrum One',
nativeCurrency: ETH,
blockExplorerUrls: ['https://arbiscan.io'],
},
421611: {
urls: [
process.env.infuraKey ? `https://arbitrum-rinkeby.infura.io/v3/${process.env.infuraKey}` : undefined,
process.env.infuraKey ? `https://arbitrum-rinkeby.infura.io/v3/${process.env.infuraKey}` : '',
'https://rinkeby.arbitrum.io/rpc',
].filter((url) => url !== undefined),
].filter((url) => url !== ''),
name: 'Arbitrum Testnet',
nativeCurrency: ETH,
blockExplorerUrls: ['https://testnet.arbiscan.io'],
},
// Polygon
137: {
urls: [
process.env.infuraKey ? `https://polygon-mainnet.infura.io/v3/${process.env.infuraKey}` : undefined,
process.env.infuraKey ? `https://polygon-mainnet.infura.io/v3/${process.env.infuraKey}` : '',
'https://polygon-rpc.com',
].filter((url) => url !== undefined),
].filter((url) => url !== ''),
name: 'Polygon Mainnet',
nativeCurrency: MATIC,
blockExplorerUrls: ['https://polygonscan.com'],
},
80001: {
urls: [process.env.infuraKey ? `https://polygon-mumbai.infura.io/v3/${process.env.infuraKey}` : undefined].filter(
(url) => url !== undefined
urls: [process.env.infuraKey ? `https://polygon-mumbai.infura.io/v3/${process.env.infuraKey}` : ''].filter(
(url) => url !== ''
),
name: 'Polygon Mumbai',
nativeCurrency: MATIC,
Expand Down

0 comments on commit b1786d3

Please sign in to comment.