From d0a985bc8ac3eaa3d47d688f7c00ce2df221bba3 Mon Sep 17 00:00:00 2001 From: Quazia Date: Tue, 31 Oct 2023 17:02:25 -0400 Subject: [PATCH] Feat(paraswap): add optimism to swap --- packages/paraswap/src/chain-ids.ts | 2 +- packages/paraswap/src/contract-addresses.ts | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/packages/paraswap/src/chain-ids.ts b/packages/paraswap/src/chain-ids.ts index 0cd36f429..7b0732e33 100644 --- a/packages/paraswap/src/chain-ids.ts +++ b/packages/paraswap/src/chain-ids.ts @@ -3,5 +3,5 @@ export const ETH_CHAIN_ID = 1 export const ARB_ONE_CHAIN_ID = 42161 export const OPTIMISM_CHAIN_ID = 10 -export const SWAP_CHAIN_ID_ARRAY = [ETH_CHAIN_ID, ARB_ONE_CHAIN_ID] +export const SWAP_CHAIN_ID_ARRAY = [ETH_CHAIN_ID, ARB_ONE_CHAIN_ID, OPTIMISM_CHAIN_ID] export const STAKE_CHAIN_ID_ARRAY = [ETH_CHAIN_ID, OPTIMISM_CHAIN_ID] diff --git a/packages/paraswap/src/contract-addresses.ts b/packages/paraswap/src/contract-addresses.ts index 1e63bf229..9485fba3f 100644 --- a/packages/paraswap/src/contract-addresses.ts +++ b/packages/paraswap/src/contract-addresses.ts @@ -35,6 +35,26 @@ export const DEFAULT_SWAP_TOKEN_LIST: { '0xaf88d065e77c8cc2239327c5edb3a432268e5831', '0xf97f4df75117a78c1a5a0dbb814af92458539fb4', ], + [OPTIMISM_CHAIN_ID]: [ + '0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee', + '0x4200000000000000000000000000000000000006', + '0x4200000000000000000000000000000000000042', + '0x76fb31fb4af56892a25e32cfc43de717950c9278', + '0xda10009cbd5d07dd0cecc66161fc93d7c9000da1', + '0x94b008aa00579c1307b0ef2c499ad98a8ce58e58', + '0x350a791bfc2c21f9ed5d10980dad2e2638ffa7f6', + '0x8c6f28f2f1a3c87f0f938b96d27520d9751ec8d9', + '0x7f5c764cbc14f9669b88837ca1490cca17c31607', + '0x68f180fcce6836688e9084f035309e29bf0a2095', + '0xf329e36c7bf6e5e86ce2150875a84ce77f477375', + '0x82e64f49ed5ec1bc6e43dad4fc8af9bb3a2312ee', + '0x6ab707aca953edaefbc4fd23ba73294241490620', + '0x191c10aa4af7c30e871e70c95db0e4eb77237530', + '0x6d80113e533a2c0fe82eabd35f1875dcea89ea97', + '0x625e7708f30ca75bfd92586e17077590c60eb4cd', + '0x078f358208685046a11c85e8ad32895ded33a249', + '0xe50fa9b3c56ffb159cb0fca61f5c9d750e8128c8' + ] } as const export const DEFAULT_STAKE_TOKEN_LIST: {