Skip to content

Commit 0a2eb5c

Browse files
authored
Add CLI steps to Web3Auth Quickstart (#2075)
* Add CLI steps to Web3Auth Quickstart * Update Dynamic Quickstart with latest CLI options
1 parent 77ba0f1 commit 0a2eb5c

File tree

2 files changed

+57
-2
lines changed

2 files changed

+57
-2
lines changed

sdk/quickstart/javascript-dynamic.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ The project you will set up has the following structure:
6161

6262
```bash
6363
? Please select the template you want to use:
64-
Next.js Quickstart (MetaMask SDK Example) (Recommended)
64+
MetaMask <-> Next.js (Wagmi) Quickstart (Recommended)
65+
MetaMask <-> Web3Auth Quickstart
6566
❯ MetaMask <-> Dynamic Quickstart
6667
```
6768

sdk/quickstart/javascript-web3auth.md

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,60 @@ Features include:
3333
- [MetaMask](https://metamask.io/) installed in your browser or on mobile.
3434
- A [Web3Auth Client ID](https://web3auth.io/docs/dashboard/create-new-project#get-the-client-id).
3535

36+
## Set up using the CLI
37+
38+
1. Run the CLI command, replacing `<project-name>` with your project name:
39+
40+
```bash
41+
npx @consensys/create-web3-app <project-name>
42+
```
43+
44+
1. Select the Web3Auth Quickstart template:
45+
46+
```bash
47+
? Please select the template you want to use:
48+
MetaMask <-> Next.js (Wagmi) Quickstart (Recommended)
49+
❯ MetaMask <-> Web3Auth Quickstart
50+
MetaMask <-> Dynamic Quickstart
51+
```
52+
53+
1. Select your preferred blockchain tooling if your project requires it:
54+
55+
```bash
56+
? Would you like to include blockchain tooling? (Use arrow keys)
57+
HardHat
58+
Foundry
59+
❯ None
60+
```
61+
62+
1. Select your preferred package manager.
63+
We recommend pnpm for speed and efficiency:
64+
65+
```bash
66+
? Please select the package manager you want to use:
67+
Yarn
68+
NPM
69+
❯ pnpm
70+
```
71+
72+
1. Select to enter your Web3Auth Client ID in the command prompt:
73+
74+
```bash
75+
Note: The selected template requires a Web3Auth client ID.
76+
You can obtain one from https://dashboard.web3auth.io and later
77+
add NEXT_PUBLIC_WEB3AUTH_CLIENT_ID=<your_client_id> to a .env file in your site's directory.
78+
```
79+
80+
1. The CLI will take a few minutes to set up your project.
81+
Once complete, you can run the project using the following command in `cd <project-name>`:
82+
83+
```bash
84+
pnpm run dev
85+
```
86+
87+
You've successfully set up MetaMask SDK and Web3Auth SDK.
88+
See how to [use the Web3Auth SDK](#usage).
89+
3690
## Set up using a template
3791
3892
1. Download the [MetaMask SDK + Web3Auth SDK template](https://github.com/MetaMask/metamask-web3auth):
@@ -72,7 +126,7 @@ Features include:
72126
```
73127
74128
You've successfully set up MetaMask SDK and Web3Auth SDK.
75-
See how to [use the combined SDKs](#usage).
129+
See how to [use the Web3Auth SDK](#usage).
76130
77131
## Set up manually
78132

0 commit comments

Comments
 (0)