📃Smart Contracts

Smart contracts hold an essential role in the blockchain ecosystem of dApps. It is critical to ensure they work as intended and remain as secure as possible. Complete and well-design smart contracts save us from unnecessary financial losses and help the project stay secure. Smart contract verification is sometimes overlooked when teams are rushing to ship, but it is vital to verify smart contracts on their correctness, validity and security.

The following documentation demonstrates the deployment and verification of a smart contract by Solidity to Planq. @openzeppelin/contracts is used for the demo Solidity script. Both Truffle and Hardhat for deployment are included in this documentation and you shall use one of your choices. We also walk through the steps of verifying a smart contract with the Hardhat Planq EVM Explorer plugin on Planq.

Pre-requisites

Below are the prerequisites for contract deployment and verification.

Supported OS

We officially support macOS, Windows and Linux only. Other platforms may work but there is no guarantee. We will extend our support to other platforms after we have stabilized our current architecture.

Prepare nodejs and npm environment

You can refer to Downloading and installing Node.js and npm Nodejs v10 is suggested

Git clone smart-contract-example

$ git clone git@github.com:crypto-org-chain/planq-smart-contract-example.git

Once you have them all ready, now we are ready to go through the next step of contract deployment and verification!

Last updated