使用工具:remix、vscode、ganache、ethers.js、metamask、nodejs、solidity语言、网页控制台、终端命令行

web3开发:前端开发 ethers.js

web3开发:前端使用ethers.js调用Hello智能合约。

hello.sol 智能合约文件:

// SPDX-License-Identifier: MITpragma solidity 0.8.0;contract Hello {function greet() external pure returns(string memory) {return "Hello web3";}}

dapp.html 前端文件:

<button οnclick="runContr