Skip to content

Commit

Permalink
Reduce text and streamline MetaMask Connect page to ensure developers…
Browse files Browse the repository at this point in the history
… can easily make a decision on this page.
  • Loading branch information
httpJunkie committed Sep 20, 2024
1 parent 714398b commit 5e4e0b3
Showing 1 changed file with 17 additions and 45 deletions.
62 changes: 17 additions & 45 deletions wallet/connect/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ description: Connect to MetaMask using various options.

# Connect to MetaMask

You can connect your dapp to MetaMask in the following ways:
There are several ways to connect your dapp to MetaMask:

- Using [MetaMask SDK](metamask-sdk/index.md)
- Using third-party libraries that support the SDK, such as [Wagmi](3rd-party-libraries/wagmi.md) or
- [MetaMask SDK](metamask-sdk/index.md)
- Third-party libraries that support the SDK, such as [Wagmi](3rd-party-libraries/wagmi.md) or
[Web3-Onboard](3rd-party-libraries/web3-onboard.md)
- Directly using the [Wallet API](wallet-api.md)
- The [Wallet API](wallet-api.md)

The following table compares the supported features of each connection option:

Expand All @@ -23,57 +23,29 @@ The following table compares the supported features of each connection option:

## MetaMask SDK

MetaMask SDK is a library that provides a reliable, secure, and seamless connection from your dapp
to the MetaMask browser extension and MetaMask Mobile.
You can install the SDK in existing dapps, and call any Wallet API methods from your dapp.
Key features of MetaMask SDK include:
The **MetaMask SDK** provides your users with a reliable and secure way to connect to MetaMask Mobile from any platform. From a web dapp you can also give your users the option of connecting to the MetaMask Browser Extension. It's flexible and can be integrated into existing projects without altering the underlying calls to the Wallet API and we have you covered on web, iOS, Android and Unity.

- **Connection to MetaMask extension and Mobile** - For web dapps, users have the option of connecting
to the MetaMask browser extension or to MetaMask Mobile using a QR code.
Connecting to MetaMask Mobile creates a persistent connection between the dapp and the mobile wallet.
Key features include:

- **Multiple supported dapp platforms** - You can connect from web, desktop, mobile, and gaming dapps
to MetaMask Mobile.

- **EIP-6963 detection** - The SDK detects MetaMask using the
[EIP-6963 multi-wallet detection mechanism](../concepts/wallet-interoperability.md).
When used on its own, the SDK discovers *only* the MetaMask wallet.
You can also use the SDK with [third-party libraries](#third-party-libraries), where its only job
is to detect and connect to MetaMask, and the libraries handle detecting other wallets.
- **Multi-platform support** – Connect from web, desktop, mobile, or gaming platforms.
- **Seamless mobile integration** – Use QR codes or deep links to create persistent connections with MetaMask Mobile.
- **EIP-6963 detection** – Automatically detect MetaMask wallets with or without third-party libraries.
- **RPC request batching** – Enhance efficiency by batching multiple requests into a single call.

Get started with [MetaMask SDK](metamask-sdk/index.md).

## Third-party libraries

MetaMask SDK is fully integrated with third-party libraries such as Wagmi and Web3-Onboard.
These libraries enable multi-wallet support in your dapp, and provide pre-built tools for managing
wallet connections, enabling more flexibility in how users connect to your dapp.
Key benefits of third-party libraries include:

- **Simplified connection logic** – Third-party libraries handle much of the complexity of wallet
integrations, saving development time and reducing the need to manage multiple connection states manually.

- **Feature-rich ecosystem** – Many libraries come with additional features such as hooks (Wagmi) or
connection management tools (Web3-Onboard), providing a more structured way to implement wallet
connections in dapps.
MetaMask SDK integrates smoothly with libraries like Wagmi and Web3-Onboard, which simplify wallet connections and support multiple wallets. These libraries offer tools to streamline connection logic and provide additional features for managing wallets.

However, you should also consider the trade-offs of third-party libraries:
Consider the trade-offs:
- **Less control** over specific MetaMask features.
- **Inconsistent behavior** across different wallets due to multi-wallet support.

- **Reduced control** – Third-party libraries might limit direct access to certain MetaMask-specific
features or custom integrations, because they abstract some connection logic.

- **Cross-wallet compatibility** – Since these libraries support multiple wallets, not all
wallet-specific features are available or guaranteed to behave consistently across different wallets.

In general, using the MetaMask SDK integration with third-party libraries can provide the best of
both worlds: broad wallet support and the reliability of MetaMask's advanced features.
Get started with [Wagmi](3rd-party-libraries/wagmi.md) or
[Web3-Onboard](3rd-party-libraries/web3-onboard.md).
Explore [Wagmi](3rd-party-libraries/wagmi.md) and [Web3-Onboard](3rd-party-libraries/web3-onboard.md).

## Wallet API

You can connect to MetaMask using the Wallet API directly, without the SDK.

*Paragraph explaining use cases for connecting directly via Wallet API.*
You can also directly integrate MetaMask using the Wallet API, which allows you to manage Ethereum accounts, sign data, and send transactions without requiring the SDK.

Get started with the [Wallet API](wallet-api.md).
Learn more about the [Wallet API](wallet-api.md).

0 comments on commit 5e4e0b3

Please sign in to comment.