Skip to content

Commit 139f24d

Browse files
committed
Dev tools: Matic.js doc update
- Combining two pages - Adding redirect
1 parent 4655d35 commit 139f24d

File tree

7 files changed

+44
-50
lines changed

7 files changed

+44
-50
lines changed

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

Lines changed: 1 addition & 1 deletion
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

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ 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 "
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.

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

mkdocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,6 @@ nav:
441441
- Venly NFT API: https://docs.venly.io/docs/nft-api-getting-started
442442
- Venly Zapier integration: https://docs.venly.io/docs/zapier-integration
443443
- Matic.js:
444-
- Installation: tools/matic-js/installation.md
445444
- Get started: tools/matic-js/get-started.md
446445
- POS:
447446
- POS client: tools/matic-js/pos/client.md
@@ -675,6 +674,7 @@ plugins:
675674
'cdk/getting-started/index.md': 'cdk/getting-started/local-deployment.md'
676675
'zkEVM/how-to/index.md': 'zkEVM/get-started/index.md'
677676
'cdk/concepts/index.md': 'cdk/concepts/layer2s.md'
677+
'tools/matic-js/installation.md': 'tools/matic-js/get-started.md'
678678

679679

680680
validation:

0 commit comments

Comments
 (0)