Smart Contract

DxChain 3.0 is fully compatible with smart contract technologies that run on Ethereum.

Remix

Setup DxChain 3.0 in Metamask, select injected web3for the environment in Remix, keep the same with the network in Metamask.

Createsol file, write smart contracts

// SPDX-License-Identifier: GPL-3.0

pragma solidity >=0.7.0 <0.9.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

contract TestToken is ERC20("TestToken", "TT") {}

Select the appropriate version of the solidity compiler, set automatic compilation and optimization, then perform contract compilation.

Select the injected web3 network to deploy the smart contract.

The contract deployment is completed after the transaction is sent.

Other

  • hardhat

  • truffle

  • ......

Last updated