Injected Solana Provider
Connecting accounts
Connecting
To establish a connection to a user’s account, call the connect
method on the provider.
If the user accepts the request and the connection is successful, the publicKey
field is set to the PublicKey of the connected account, and the isConnected
field is set to true
.
If the user rejects the request to connect, an error is thrown.
Disconnecting
To disconnect a user’s account from your application, call the disconnect
method on the provider.
If the user’s account is disconnected, the publicKey
field is set to null
, and the isConnected
field is set to false
.