TxnLab / use-wallet

A framework agnostic wallet integration library for Algorand dApps
https://txnlab.gitbook.io/use-wallet
MIT License
81 stars 31 forks source link

move the algod client to store #213

Closed drichar closed 1 week ago

drichar commented 1 month ago

When switching networks, the algod client needs to be reactive in order to continue working on the new network. This is currently only working in the SolidJS adapter thanks to https://github.com/TxnLab/use-wallet/pull/204, which moved the client to the @tanstack/solid-store reactive store.

The same should be done in the core library and the other framework adapters.

SilentRhetoric commented 3 weeks ago

I want to add that the algodClient is currently reactive in the SolidJS adapter, but it is not being set when the app is first initialized. In order to get this working generically, the store will need to have its algodClient set from the active network when the app first mounts.

drichar commented 1 week ago

Closed by https://github.com/TxnLab/use-wallet/pull/224