Skip to content

Commit db2784f

Browse files
committed
address feedback
1 parent d0ead25 commit db2784f

File tree

4 files changed

+18
-17
lines changed

4 files changed

+18
-17
lines changed

developer-docs-site/docs/concepts/wallet-adapter-concept.md

+10-10
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ The [Adapter Core package](https://github.com/aptos-labs/aptos-wallet-adapter/tr
2828
- Holds the current wallet state and the installed wallets
2929
- Emits events on different actions and much more
3030

31-
Dapps should not *know* this package as dapps interact with the provider, which in turn interacts with the core package; some Types are exposed from the core package for the dapp to use.
31+
Dapps should not _know_ this package as dapps interact with the provider, which in turn interacts with the core package; some Types are exposed from the core package for the dapp to use.
3232

3333
Wallets should implement their own plugin class that extends the basic plugin class (properties + events) interface that lives in the core package.
3434

@@ -56,20 +56,20 @@ When we started building a wallet adapter, we wanted a structure that can be eas
5656

5757
We did research on the existing adapters, got some feedback from our community, and designed this structure to help wallets and dapps in development and when going to production. This structure offers the following benefits:
5858

59-
* Modularity (separation of concerns) - separating the adapter into three components can help having more freedom in design, implementation, deployment and usage.
60-
* Wallets create and own their plugin implementation (instead of having all in the same monorepo):
61-
- Reduces the packages bundle size used by dapps.
62-
- Lets them be self-service and support themselves without too much friction.
63-
- Prevents build failures in case of any bugs/bad implementation/wrong config files/etc.
64-
* Simplicity - keeps the Provider package very light and small as the major logic is implemented in the core package.
65-
* Flexibility - for wallets in creating and implementing custom functions.
59+
- Modularity (separation of concerns) - separating the adapter into three components can help having more freedom in design, implementation, deployment and usage.
60+
- Wallets create and own their plugin implementation (instead of having all in the same monorepo):
61+
- Reduces the packages bundle size used by dapps.
62+
- Lets them be self-service and support themselves without too much friction.
63+
- Prevents build failures in case of any bugs/bad implementation/wrong config files/etc.
64+
- Simplicity - keeps the Provider package very light and small as the major logic is implemented in the core package.
65+
- Flexibility - for wallets in creating and implementing custom functions.
6666

6767
<center>
6868
<ThemedImage
6969
alt="Wallet Adapter Concept"
7070
sources={{
71-
light: useBaseUrl('/img/docs/10-adapter-chart-light.svg'),
72-
dark: useBaseUrl('/img/docs/10-adapter-chart-dark.svg'),
71+
light: useBaseUrl('/img/docs/wallet-adapter-chart-light.svg'),
72+
dark: useBaseUrl('/img/docs/wallet-adapter-chart-dark.svg'),
7373
}}
7474
/>
7575
</center>

developer-docs-site/docs/guides/wallet-adapter-for-dapp.md

+8-7
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ The Aptos Wallet Adapter provides:
2424

2525
## Setup
2626

27-
Currently, the adapter supports a *React provider* for you to include in your app.
27+
Currently, the adapter supports a _React provider_ for you to include in your app.
2828

2929
Install wallet dependencies you want to include in your app. You can find a list of the wallets in the Aptos Wallet Adapter [README](https://github.com/aptos-labs/aptos-wallet-adapter#supported-wallet-packages).
3030

@@ -34,13 +34,14 @@ Install the React provider:
3434
npm install @aptos-labs/wallet-adapter-react
3535
```
3636

37-
Import dependencies:
38-
TODO: How?
37+
### Import dependencies:
3938

40-
On the App.jsx file, Import the installed wallets:
39+
On the App.jsx file,
40+
41+
Import the installed wallets:
4142

4243
```js
43-
import { AptosWallet } from "some-aptos-wallet-package";
44+
import { PetraWallet } from "petra-plugin-wallet-adapter";
4445
```
4546

4647
Import the AptosWalletAdapterProvider:
@@ -52,13 +53,13 @@ import { AptosWalletAdapterProvider } from "@aptos-labs/wallet-adapter-react";
5253
Wrap your app with the Provider, pass it the plugins (wallets) you want to have on your app as an array, and include an autoConnect option (set to false by default)
5354

5455
```js
55-
const wallets = [new AptosWallet()];
56+
const wallets = [new PetraWallet()];
5657
<AptosWalletAdapterProvider plugins={wallets} autoConnect={true}>
5758
<App />
5859
</AptosWalletAdapterProvider>;
5960
```
6061

61-
## Use
62+
### Use
6263

6364
On any page you want to use the wallet properties, import `useWallet` from `@aptos-labs/wallet-adapter-react`:
6465

0 commit comments

Comments
 (0)