watchUser
Watches for changes to the user in the client store and triggers the provided callback when a change is detected.
Import
Usage
Parameters
config
AlchemyAccountsConfig
the configuration containing the client store
Returns
(onChange: (user: User) => void) => (() => void)
a function which accepts a callback that fires when the user changes and returns a function to unsubscribe from the user updates