You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: embedded-wallets/connect-blockchain/evm/README.mdx
+4-1Lines changed: 4 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,6 +22,9 @@ With Embedded Wallets v11 onward, chains are already added to the dashboard. You
22
22
23
23
::::
24
24
25
-
The Embedded Wallets Web SDK(`@web3auth/modal`) from v11 onward does not need any additional setup on the code side for blockchain connections. All of it is handled on the dashboard. We can use any chain from the extensive list of predefined chains and add more if we need.
25
+
The Embedded Wallets Web SDK (`@web3auth/modal`) does not need any additional setup on the code side for standard EVM connections. Chains enabled in the dashboard are loaded automatically
26
+
at runtime.
27
+
28
+
You can still pass a `chains` array in `web3AuthOptions` when you need custom RPC endpoints, local testing overrides, or patterns shown in SDK demo apps. Prefer [dashboard chain configuration](/embedded-wallets/dashboard/chains-and-networks/) for production.
26
29
27
30

|`chains?`|Optional in-code chain list. By default, chains are fetched from the [dashboard](/embedded-wallets/dashboard/chains-and-networks/). Pass `chains`only for custom RPC, demos, or overrides. |
33
+
|`uiConfig?`| (Fetched automatically from dashboard) Config for configuring UI display properties. |
34
+
|`modalConfig?`| Helps you customize the modal UI elements and authentication methods. |
35
+
|`accountAbstractionConfig?`| (Fetched automatically from Dashboard) Account abstraction config for your chain namespace. |
36
+
|`useAAWithExternalWallet?`| (Fetched automatically from Dashboard) Whether to use AA with external wallet. |
37
+
|`walletServicesConfig?`| (Fetched automatically from Dashboard) Configure any parameter related to Wallet Services plugin |
38
+
|`ssr?`| Whether to enable SSR mode. |
39
+
|`mfaSettings?`| MFA settings for the auth connector. |
40
+
|`mfaLevel?`| MFA level for the auth connector. |
41
+
|`privateKeyProvider?`| Private key provider for your chain namespace. |
MetaMask Embedded Wallets SDK (formerly Web3Auth Plug and Play) provides a seamless authentication experience for React applications with social logins, external wallets, and more. Our React Hooks simplifies how you connect users to their preferred wallets and manage authentication state.
13
+
MetaMask Embedded Wallets SDK (formerly Web3Auth Plug and Play) provides a seamless authentication
14
+
experience for React applications with social logins, external wallets, and more. React hooks
15
+
simplify how you connect users to their preferred wallets and manage authentication state.
Create a configuration file for Web3Auth. This file will contain your Web3Auth Client ID and Network details from the [Embedded Wallets dashboard](https://developer.metamask.io/).
47
+
Create a configuration file with your Client ID and Sapphire network from the
clientId: 'YOUR_WEB3AUTH_CLIENT_ID', // Pass your Web3Auth Client ID, ideally using an environment variable // Get your Client ID from MetaMask Developer Dashboard
50
-
web3AuthNetwork: WEB3AUTH_NETWORK.SAPPHIRE_MAINNET, // or WEB3AUTH_NETWORK.SAPPHIRE_DEVNET
51
-
}
57
+
const clientId =import.meta.env.VITE_WEB3AUTH_CLIENT_ID// or your env prefix
Web3Auth is blockchain agnostic, enabling integration with any blockchain network. Out of the box, Web3Auth offers robust support for both **Solana** and **Ethereum**, each with dedicated React hooks.
228
+
Web3Auth is blockchain agnostic, enabling integration with any blockchain network. Out of the box,
229
+
Web3Auth offers robust support for both **Solana** and **Ethereum**, each with dedicated React hooks.
183
230
184
231
### Solana integration
185
232
186
-
Solana hooks are included natively within the `@web3auth/modal` package. No additional setup is required—simply use the provided hooks to interact with Solana networks.
233
+
Solana hooks are included natively within the `@web3auth/modal` package. Install
234
+
[`@solana/kit`](https://www.npmjs.com/package/@solana/kit) and use hooks from
235
+
`@web3auth/modal/react/solana`.
187
236
188
237
For detailed usage and examples, see the [**Solana hooks**](./solana-hooks/README.mdx) section.
189
238
190
239
### Ethereum integration
191
240
192
-
Ethereum hooks are provided through the popular `wagmi` library, which works seamlessly with Web3Auth. This allows you to leverage a wide range of Ethereum hooks for account management, transactions, and more.
241
+
Ethereum wallet operations use [Wagmi](https://wagmi.sh/) hooks after the provider setup above.
242
+
Configure EVM chains in the [Embedded Wallets dashboard](../../dashboard/chains-and-networks/); no
243
+
in-app chain list is required for standard integrations.
193
244
194
-
For implementation details and examples, refer to the [**Ethereum Hooks**](./ethereum-hooks.mdx) section.
245
+
For implementation details and examples, refer to the [**Ethereum hooks**](./ethereum-hooks.mdx) section.
0 commit comments