Skip to content

Commit 1d84070

Browse files
authored
Merge pull request 0xPolygon#704 from 0xPolygon/devtools-review-updates
Dev tools: restructuring and update
2 parents 1ecd7a7 + 208c9ec commit 1d84070

File tree

12 files changed

+131
-143
lines changed

12 files changed

+131
-143
lines changed

docs/pos/get-started/building-on-polygon.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Use the links below to find the right tooling and guides that suit your needs th
1414
- [Polygon gas station](../../tools/gas/polygon-gas-station.md) - Gas estimation API
1515
- [Polygon dApp Launchpad](../../tools/dApp-development/launchpad/intro.md) - dApp development CLI tool
1616
- [Popular third-party tooling](../../tools/dApp-development/third-party-tutorials.md)
17-
- [Matic.js library](../../tools/matic-js/installation.md)
17+
- [Matic.js library](../../tools/matic-js/get-started.md)
1818

1919
If you have no prior experience in dApp development, the following resources will help you get started with some essential tools for building, testing, and deploying applications on Polygon PoS.
2020

@@ -44,7 +44,6 @@ There are several other third-party wallet options available to choose from, and
4444

4545
Refer to the following guides and follow along to set up your wallet for making web3 function calls:
4646

47-
- [MetaMask](../../tools/wallets/metamask/index.md)
4847
- [Venly](../../tools/wallets/venly/index.md)
4948

5049
## Common tasks

docs/tools/dApp-development/common-tools/remix.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ The `update` function is another public function that is similar to the constr
7979

8080
Now, we have to deploy our smart contract on Amoy, the Polygon testnet. Not only does it cost money (e.g., gas fees) to deploy a smart contract on Polygon mainnet, but the contract is immutable and can't be changed once deployed. Therefore, it's best to deploy your smart contract to the testnet first.
8181

82-
To deploy to the Amoy testnet, we have to connect to the web3 with a service like MetaMask, Brave, Portis, etc. We use MetaMask in this tutorial. Please follow this [guide to set up a MetaMask account](../../wallets/metamask/index.md).
82+
To deploy to the Amoy testnet, we have to connect to the web3 with a service like MetaMask, Brave, Portis, etc. We use MetaMask in this tutorial. Please follow this [guide to set up a MetaMask account](https://support.metamask.io/getting-started/getting-started-with-metamask/).
8383

8484
- Open Metamask. Click on the network dropdown menu (set to **Ethereum Mainnet** by default) and click on the **Add Network** button. MaticVigil provides a public endpoint and is rate-limited. Therefore, most developers use a free blockchain provider like [Alchemy](https://docs.alchemy.com/docs/how-to-add-polygon-to-metamask) or [Quicknode](https://www.quicknode.com/guides/smart-contract-development/how-to-deploy-a-smart-contract-on-maticpolygon#setting-up-metamask-with-polygon-node) to have a dedicated RPC endpoint with faster throughput AKA computing units per second (CUPs). You need to create a free account to get your private API key from one of these providers to put into the dedicated RPC endpoint URL below.
8585

docs/tools/dApp-development/common-tools/replit.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ You need a browser-based web3 wallet to interact with the Polygon Amoy testnet a
2929
You must set up all of the following prerequisites to be able to deploy your solidity smart contract on Polygon:
3030

3131
1. [Create a Replit account](https://replit.com/signup).
32-
2. [Download MetaMask wallet](../../wallets/metamask/index.md).
32+
2. [Download MetaMask wallet](https://support.metamask.io/getting-started/getting-started-with-metamask/).
3333
3. [Configure Polygon on MetaMask](../../wallets/metamask/add-polygon-network.md).
3434
4. [Get testnet tokens](https://faucet.polygon.technology).
3535

docs/tools/dApp-development/launchpad/quickstart.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,15 +53,15 @@ There are mandatory environment variables in both the `frontend` and `smart-cont
5353

5454
3. Open the `.env` file and add the `NEXT_PUBLIC_WALLETCONNECT_PROJECT_ID` to the file.
5555

56-
!!! info "How to get the WalletConnect project id"
56+
!!! info "How to get the WalletConnect project ID"
5757
You can get the variable by creating an application on [WalletConnect](https://cloud.walletconnect.com/).
5858

5959
1. Create an account and sign in.
6060
2. Select **Create a new project**.
61-
3. Give it a name and select **App**.
62-
4. The URL can be blank.
63-
5. Click the **Create** button underneath the project box.
64-
6. Copy the project id and paste it into the frontend `.env` file.
61+
3. Give it a name and select **Continue**. You can leave the URL empty for now.
62+
4. Select **AppKit** and continue.
63+
5. Select **Next.js** and then select the **Create** button the bottom right of the pop-up window.
64+
6. This brings up the dashboard. Copy the project ID form the sidebar on the left and paste it into the frontend `.env` file.
6565

6666
4. Navigate to the smart-contracts directory and copy the example file.
6767

docs/tools/gas/matic-faucet.md

Lines changed: 30 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -2,45 +2,39 @@
22
comments: true
33
---
44

5-
The Polygon Faucet is a tool provided by Polygon and ecosystem partners like Alchemy, QuickNode, and GetBlock. It enables developers to acquire free MATIC/ETH test tokens on the PoS Amoy and zkEVM Cardona testnets. Start deploying and testing your dApps on the Polygon network with test tokens that allow you to explore Polygon features without spending actual MATIC tokens on the mainnet.
6-
7-
Polygon Faucet drips:
8-
9-
- MATIC on PoS Amoy and Ethereum Sepolia.
10-
- Test ETH on zkEVM Cardona.
11-
125
!!! info "Testnet tokens hold no real-world value"
136
Tokens on testnets such as PoS Amoy, Ethereum Sepolia, and zkEVM Cardona hold no real value and are solely used for testing purposes.
147

15-
Several faucet tools are available to receive test MATIC and ETH on Sepolia-anchored Polygon networks:
8+
Several faucet tools are available to receive test POL and ETH on Sepolia-anchored Polygon networks:
169

17-
| Faucet | Supported networks |
18-
| :----------------------: | --------------------------------------------------------------------------------------------------------------------- |
19-
| Polygon Faucet | [zkEVM Cardona, PoS Amoy, Ethereum Sepolia](https://faucet.polygon.technology) |
20-
| Alchemy Faucet | [PoS Amoy](https://www.alchemy.com/faucets/polygon-amoy) \| [Ethereum Sepolia](https://www.alchemy.com/faucets/ethereum-sepolia) |
21-
| QuickNode Polygon Faucet | [PoS Amoy](https://faucet.quicknode.com/polygon/amoy) |
22-
| GetBlock Faucet | [PoS Amoy](https://getblock.io/faucet/matic-amoy/) \| [Ethereum Sepolia](https://getblock.io/faucet/eth-sepolia) |
10+
| Faucet | Supported networks |
11+
| :----------------------: | -------------------------------------------------------------------------------------------------------------------------------- |
12+
| Polygon Faucet | [zkEVM Cardona, PoS Amoy, Ethereum Sepolia](https://faucet.polygon.technology) |
13+
| Alchemy Faucet | [PoS Amoy](https://www.alchemy.com/faucets/polygon-amoy) \| [Ethereum Sepolia](https://www.alchemy.com/faucets/ethereum-sepolia) |
14+
| QuickNode Polygon Faucet | [PoS Amoy](https://faucet.quicknode.com/polygon/amoy) |
15+
| GetBlock Faucet | [PoS Amoy](https://getblock.io/faucet/matic-amoy/) \| [Ethereum Sepolia](https://getblock.io/faucet/eth-sepolia) |
2316

2417
## Polygon Faucet
2518

19+
The Polygon Faucet is a tool provided by Polygon and ecosystem partners like Alchemy, QuickNode, and GetBlock. It enables developers to acquire free POL/ETH test tokens on the PoS Amoy and zkEVM Cardona testnets. Start deploying and testing your dApps on the Polygon network with test tokens that allow you to explore Polygon features without spending actual POL tokens on the mainnet.
20+
21+
Polygon Faucet drips:
22+
23+
- POL on PoS Amoy.
24+
- POL and a dummy ERC20 token on Ethereum Sepolia.
25+
- Test ETH on zkEVM Cardona.
26+
2627
- Start by navigating to [faucet.polygon.technology](https://faucet.polygon.technology/) and connecting/verifying your Discord by selecting **Connect Discord** in the top-right corner of the page.
2728

2829
<center>
2930
![img](../../img/tools/gas/faucet.png){width=70%}
3031
</center>
3132

32-
- Select one of the blockchain testnet networks from the drop-down list:
33-
34-
- **Polygon zkEVM (Cardona)**
35-
- **Polygon PoS Amoy (Amoy)**
36-
- **Sepolia**
33+
- Select one of the blockchain testnet networks from the drop-down list. We'll select **Polygon zkEVM (cardona)** for this example.
3734

38-
- Select the type of token you want to receive:
39-
40-
- **zkEVM ETH**: Testnet ETH on zkEVM Cardona.
41-
- **MATIC**: Testnet MATIC on the PoS Amoy and Ethereum Sepolia.
35+
- Select the type of token you want to receive; zkEVM ETH in this case.
4236

43-
- Once done, copy your wallet address and select **Paste** to paste it in the text box. Typing is disabled to prevent entering a wrong address.
37+
- Copy your wallet address and either paste it directly in the **Wallet Address** field, or select **Paste**. Typing is disabled to prevent entering a wrong address.
4438

4539
- Select **Submit**.
4640

@@ -50,45 +44,45 @@ Several faucet tools are available to receive test MATIC and ETH on Sepolia-anch
5044
![img](../../img/tools/gas/confirm-transaction.png){width=50%}
5145
</center>
5246

53-
!!! danger
54-
55-
If you don't have enough MATIC testnet tokens in your account to pay for the gas fees, the transaction may fail. If you require testnet tokens in bulk, please fill out [this form](https://docs.google.com/forms/d/e/1FAIpQLSe4npoGldJknEs9EBtPaV3AS-0HTso2IuMWDCiMmLEMCx8euQ/viewform).
56-
5747
- Testnet tokens usually arrive within 1 to 2 minutes.
5848

5949
<center>
6050
![img](../../img/tools/gas/success.png){width=50%}
6151
</center>
6252

53+
!!! tip "Always maintain sufficient test token balance"
54+
55+
If you don't have enough POL/ETH test tokens in your wallet account to pay for gas fees when sending transactions, the action will fail. If you require testnet tokens in bulk, please fill out [this form](https://docs.google.com/forms/d/e/1FAIpQLSe4npoGldJknEs9EBtPaV3AS-0HTso2IuMWDCiMmLEMCx8euQ/viewform).
56+
6357
## Alchemy Faucet
6458

65-
!!! tip "Get 0.5 Amoy MATIC"
66-
If you sign up or log in with an Alchemy account, you get 0.5 MATIC per day. Without an account, you get 0.2.
59+
!!! tip "Get 0.5 Amoy POL"
60+
If you sign up or log in with an Alchemy account, you get 0.5 POL per day. Without an account, you get 0.2.
6761

68-
- You can request MATIC tokens from Alchemy's Amoy Faucet. In order to receive testnet tokens, head over to the [Alchemy Polygon Amoy MATIC faucet](https://www.alchemy.com/faucets/polygon-amoy), enter your wallet address and hit the **Send Me MATIC** button.
62+
- You can request POL tokens from Alchemy's Amoy Faucet. In order to receive testnet tokens, head over to the [Alchemy Polygon Amoy POL faucet](https://www.alchemy.com/faucets/polygon-amoy), enter your wallet address and hit the **Send Me POL** button.
6963

7064
![img](../../img/tools/gas/alchemy-faucet1.png)
7165

72-
- Check the transaction hash as soon as you finish requesting your MATIC, and view the transaction details on [Polygonscan](https://amoy.polygonscan.com/).
66+
- Check the transaction hash as soon as you finish requesting your POL, and view the transaction details on [Polygonscan](https://amoy.polygonscan.com/).
7367

7468
## QuickNode Polygon Faucet
7569

76-
In order to receive Amoy MATIC tokens using QuickNode faucet,
70+
In order to receive Amoy POL tokens using QuickNode faucet,
7771

7872
- Head over to the [QuickNode Polygon Faucet](https://faucet.quicknode.com/polygon). Connect your Coinbase, MetaMask, or Phantom wallet by clicking on **Connect Wallet**. Then, choose **Amoy**, and finally select **Continue**.
7973

8074
<center>
8175
![img](../../img/tools/gas/quicknode-faucet2.png){width=80%}
8276
</center>
8377

84-
!!! tip "Get 2x MATIC"
85-
Tweet the [drip faucet URL](https://faucet.quicknode.com/drip) with your wallet address to get *twice* as many MATIC testnet tokens.
78+
!!! tip "Get 2x POL"
79+
Tweet the [drip faucet URL](https://faucet.quicknode.com/drip) with your wallet address to get *twice* as many POL testnet tokens.
8680

8781
- Click on the transaction hash to view transaction details on [Polygonscan](https://amoy.polygonscan.com/).
8882

8983
## GetBlock Polygon Faucet
9084

91-
Head over to the [GetBlock Polygon Faucet](https://getblock.io/faucet/matic-amoy/) to acquire Amoy MATIC tokens using the GetBlock faucet.
85+
Head over to the [GetBlock Polygon Faucet](https://getblock.io/faucet/matic-amoy/) to acquire Amoy POL tokens using the GetBlock faucet.
9286

9387
Please register or login to request free testnet tokens.
9488

docs/tools/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@ hide:
3939
<div class="grid-item">
4040
<a href="./gas/matic-faucet">
4141
<div class="product-list-item-header">
42-
<div class="feature-card-heading">Gas faucet</div>
42+
<div class="feature-card-heading">Token faucets</div>
4343
</div>
44-
<p class="feature-paragraph">The Polygon MATIC gas faucet and gas estimation tools.</p>
44+
<p class="feature-paragraph">Different ways to fetch test POL and ETH on Polygon PoS and zkEVM network.</p>
4545
</a>
4646
</div>
4747
<div class="grid-item">

docs/tools/matic-js/get-started.md

Lines changed: 39 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,44 @@
22
comments: true
33
---
44

5-
Matic.js is a javascript library which helps in interacting with the various components of Matic Network.
5+
[Matic.js](https://github.com/maticnetwork/matic.js) a JavaScript library that facilitates interaction with the Polygon network. It provides developers with simplified operations such as depositing, transferring, and withdrawing assets, allowing them to focus on building dApps without requiring in-depth knowledge of blockchain systems.
66

7-
In this get started document we will learn about how we can setup and interact with the POS bridge.
7+
Matic.js supports two popular libraries:
88

9-
In case you face any issues or have any queries, feel free to raise a [ticket](https://support.polygon.technology/support/tickets/new) to our Support Team or reach out to us on [Discord](https://discord.com/invite/0xPolygonCommunity).
9+
1. [Web3.js](https://web3js.readthedocs.io/)
10+
2. [Ethers](https://docs.ethers.io/)
1011

11-
!!! important
12-
Make sure you have followed the [installation step](installation.md).
12+
## Prerequisites
13+
14+
Ensure that your [Node.js](https://nodejs.org/en/) version is up to date.
15+
16+
We recommend using Node.js version v18.19.1 for optimal compatibility.
17+
18+
## Installation
19+
20+
### Matic.js core library
21+
22+
The library contains core logic and provides different APIs. The user interacts mostly with this library.
23+
24+
```sh
25+
npm i @maticnetwork/maticjs
26+
```
27+
28+
### Matic.js ethers library
29+
30+
The ethers library allows us to use any ethers function. It is injected into Matic.js using plugins.
31+
32+
```sh
33+
npm install @maticnetwork/maticjs-ethers
34+
```
35+
36+
### Matic.js web3 library
37+
38+
The web3 library allows us to use any web3 function.
39+
40+
```sh
41+
npm install @maticnetwork/maticjs-web3
42+
```
1343

1444
## Initializing
1545

@@ -25,3 +55,7 @@ use(Web3ClientPlugin)
2555

2656
- Click for more details on POS applications that use [`web3js`](setup/web3js.md).
2757
- Click for more details on POS applications that use [`ethers`](setup/ethers.md).
58+
59+
## Support
60+
61+
In case you face any issues or have any queries, feel free to raise a [ticket](https://support.polygon.technology/support/tickets/new) to our Support Team or reach out to us on [Discord](https://discord.com/invite/0xPolygonCommunity).

docs/tools/matic-js/installation.md

Lines changed: 0 additions & 40 deletions
This file was deleted.

docs/tools/matic-js/pos/client.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ comments: true
33
---
44

55
!!! important
6-
Make sure you have followed the [installation](../installation.md) and [get started](../get-started.md) documentation.
6+
Make sure you have set up Matic.js by following the [get started](../get-started.md) guide.
77

88
The `POSClient` interacts with the POS bridge.
99

docs/tools/matic-js/zkevm/initialize.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ comments: true
33
---
44

55
!!! important
6-
Make sure you have followed the [installation](../installation.md) and [get started](../get-started.md) documentation.
6+
Make sure you have set up Matic.js by following the [get started](../get-started.md) guide.
77

88
The `ZkEvmClient` interacts with the zkEVM bridge.
99

0 commit comments

Comments
 (0)