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: docs/tools/matic-js/zkevm/message.md
+7-10Lines changed: 7 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
This document entails customization of wrapped tokens using adapter contracts, transfer of tokens between Ethereum and Polygon zkEVM networks, and how Matic.js can be used to bridge assets from Ethereum to Polygon zkEVM and vice versa.
1
+
This document shows you how to customize wrapped tokens using adapter contracts, transfer tokens between Ethereum and Polygon zkEVM networks, and how to use Matic.js to bridge assets from Ethereum to Polygon zkEVM and vice versa.
2
2
3
3
## Basic functions for error passing
4
4
@@ -8,7 +8,7 @@ Below we provide the two basic functions used for _error passing_ in each of the
The existing zkEVM bridge uses the ERC-20 standard contract for creating wrapped tokens depending on the token's native network.
73
72
74
-
At often times organizations want to customise their wrapped tokens by extending some functionalities.
73
+
Often, organizations want to customise their wrapped tokens by extending some functionalities.
75
74
76
-
For instance, these functionalities could include: blacklisting, putting a cap on minting, or any sound auxiliary functionality.
75
+
These functionalities could include: blacklisting, putting a cap on minting, or any sound auxiliary functionality.
77
76
78
77
This can be done by deploying adapter contracts that use the messaging layer of the bridge.
79
78
80
79
However, for the sake of maintaining consistency among wrapped tokens, strict standards must be followed when extending their functionalities.
81
80
82
-
83
81
## Standardizations
84
82
85
-
86
83
1. Adapter contracts need to implement the [Polygon bridge library](https://github.com/0xPolygonHermez/code-examples/blob/main/customERC20-bridge-example/contracts/base/PolygonERC20BridgeBase.sol) and expose `bridgeToken()` and `onMessageReceived()` functions.
87
84
2. There should be two separate adapter contracts; `OriginChainBridgeAdapter` and `WrapperChainBridgeAdapter`.
88
-
3.`bridgeToken()` function should match the exact function signature and be similar to [this](https://github.com/maticnetwork/static/blob/master/network/mainnet/cherry/artifacts/zkevm/ZkEVMBridgeAdapter.json) ABI.
85
+
3.`bridgeToken` function should match the exact function signature and be similar to [this](https://github.com/maticnetwork/static/blob/master/network/mainnet/cherry/artifacts/zkevm/ZkEVMBridgeAdapter.json) ABI.
0 commit comments