-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: revert Solana Adapter XDEFI Integration
- Loading branch information
Showing
1 changed file
with
64 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,65 @@ | ||
# Solana Adapter XDEFI Integration | ||
|
||
# Extension Wallet Solana Integration | ||
|
||
[[toc]] | ||
|
||
## Using Solana Adapter | ||
|
||
### Solana Adapter not installed | ||
|
||
Install the latest wallets package: | ||
|
||
```bash | ||
npm install @solana/wallet-adapter-xdefi@latest | ||
``` | ||
|
||
Once installed, you can add XDEFI Wallet by making adding this part of code: | ||
|
||
```js:line-numbers {0} | ||
import { XDEFIWalletAdapter } from `@solana/wallet-adapter-xdefi`; | ||
import { /* ... other adapters ... */ } from `@solana/wallet-adapter-wallets`; | ||
const wallets = useMemo( | ||
() => [ | ||
new XDEFIWalletAdapter(), | ||
// ... other adapters ... | ||
], | ||
[] | ||
); | ||
<WalletProvider autoConnect wallets={wallets}> | ||
``` | ||
|
||
### Solana Adapter already installed | ||
|
||
Install the latest wallets package: | ||
|
||
```bash | ||
npm install @solana/wallet-adapter-wallets@latest | ||
``` | ||
|
||
Once installed, you can add XDEFI Wallet by making 2 changes: | ||
|
||
```js:line-numbers {0} | ||
import { | ||
XDEFIWalletAdapter, // [!code ++] | ||
/* ... other adapters ... */ | ||
} from `@solana/wallet-adapter-wallets`; | ||
const wallets = useMemo( | ||
() => [ | ||
new XDEFIWalletAdapter(), // [!code ++] | ||
// ... other adapters ... | ||
], | ||
[] | ||
); | ||
<WalletProvider autoConnect wallets={wallets}> | ||
``` | ||
|
||
## Using XDEFI Provider | ||
|
||
## Using XDEFI SDK | ||
|
||
TBD |