Replies: 2 comments 1 reply
-
I'm also curious about how libs like wagmi can better support multi-chain apps. As far as I can tell, all popular libs are built around the assumption that they're connected to one chain at a time. As bridging solutions become more mature, it'll be more common for apps to need live connections to multiple chains simultaneously. Your proposal for a |
Beta Was this translation helpful? Give feedback.
0 replies
-
I'm using https://docs.family.co/connectkit , looks good to me |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey! I've been using wagmi + RainbowKit for an upgrade to Vaportrade
Vaportrade's primary userbase is users of the Sequence wallet, which supports being connected to multiple chains at once.
I'd like to propose that wagmi support multi-chain wallets better, such that devs can request a signer or a provider for a specific chain without setting "the current chain" of the wallet.
Motivation
To provide a seamless integration with multichain wallets, devs need to be able to access things like a
Signer
without requesting that a wallet change its "current chain", since not all multichain wallets care about a "current chain".Prior Art and API inspiration
Vaportrade needs this functionality, and so I've built a small version myself.
In my current version, I manually type-cast a connector to
(Connector | (Connector & MultiChainConnector))
, so ifisMultiChain
is true, I can access the getProvider & getSigner's additional arguments.If this were to be integrated into
wagmi
I would imagine a MultiChainConnector subclass that multichain wallets couldextend
, and we could get rid ofisMultiChain
in favor of aninstanceof
call that would show you the extrachainId
parameters.and it would be used like
The
switchChain
method could become a no-op forMultiChainConnector
instances.What else?
Any thoughts? Would love to upstream something like this :)
Beta Was this translation helpful? Give feedback.
All reactions