Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Base chain support for Superfluid #182

Merged
merged 10 commits into from
Sep 5, 2024

Conversation

gmolki
Copy link
Member

@gmolki gmolki commented Aug 28, 2024

No description provided.

@gmolki gmolki force-pushed the feat/base-blockchain-connection branch from 2e4e7bf to 3652c1f Compare August 28, 2024 17:05
@gmolki gmolki force-pushed the feat/base-blockchain-connection branch from 3652c1f to 75f621c Compare August 29, 2024 14:20
} else {
await this.provider.send('wallet_addEthereumChain', [chainOrRpc])
await this.provider.send('wallet_switchEthereumChain', [{ chainId: chainOrRpc }])
}
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Simplified this to always use wallet_switchEthereumChain as wallet_addEthereumChain was giving problems.

cc. @philogicae

Comment on lines +148 to +170
export const ChainMetadata: { [key: number]: ChainMetadataType } = {
...ChainData,
[RpcId.AVAX]: {
...ChainData[RpcId.AVAX],
tokenAddress: '0xc0Fbc4967259786C743361a5885ef49380473dCF',
superTokenAddress: '0xc0Fbc4967259786C743361a5885ef49380473dCF',
},
[RpcId.AVAX_TESTNET]: {
...ChainData[RpcId.AVAX_TESTNET],
tokenAddress: '0x1290248E01ED2F9f863A9752A8aAD396ef3a1B00',
superTokenAddress: '0x1290248E01ED2F9f863A9752A8aAD396ef3a1B00',
},
[RpcId.ETH_SEPOLIA]: {
...ChainData[RpcId.ETH_SEPOLIA],
tokenAddress: '0xc4bf5cbdabe595361438f8c6a187bdc330539c60',
superTokenAddress: '0x22064a21fee226d8ffb8818e7627d5ff6d0fc33a',
},
[RpcId.BASE]: {
...ChainData[RpcId.BASE],
tokenAddress: '0xc0Fbc4967259786C743361a5885ef49380473dCF',
superTokenAddress: '0xc0Fbc4967259786C743361a5885ef49380473dCF',
},
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added this ChainMetadata as a separate const because we are forwarding the ChainData to the provider and it was giving errors for the unsupported fields

@philogicae philogicae force-pushed the feat/base-blockchain-connection branch from 2cd2ef0 to 29a2481 Compare September 5, 2024 10:54
@nesitor nesitor merged commit ed1ef77 into main Sep 5, 2024
2 of 4 checks passed
@nesitor nesitor deleted the feat/base-blockchain-connection branch September 5, 2024 15:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants