Hooks
useReinitialize
Available from SDK V3.0+
Summary
Used to manually reinitialize the whole SDK at any point in time. It will reset not just the user state (as useRefreshUser does), but the whole SDK state including wallets, the primaryWallet, user state, etc.
An example of where this hook can be helpful is if you have multiple seperate windows (things like a Chrome extension popup and a Chrome page for the same extension) where Dynamic is active and you want to ensure they are all in sync.
While in process, the sdkHasLoaded
boolean on useDynamicContext
will be false, and once completed, it will be true.
Usage
Was this page helpful?