MCPcopy Index your code
hub / github.com/LearnWeb3DAO/NFT-Collection / main

Function main

hardhat-tutorial/scripts/sample-script.js:8–23  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

6const hre = require("hardhat");
7
8async function main() {
9 // Hardhat always runs the compile task when running scripts with its command
10 // line interface.
11 //
12 // If this script is run directly using `node` you may want to call compile
13 // manually to make sure everything is compiled
14 // await hre.run('compile');
15
16 // We get the contract to deploy
17 const Greeter = await hre.ethers.getContractFactory("Greeter");
18 const greeter = await Greeter.deploy("Hello, Hardhat!");
19
20 await greeter.deployed();
21
22 console.log("Greeter deployed to:", greeter.address);
23}
24
25// We recommend this pattern to be able to use async/await everywhere
26// and properly handle errors.

Callers 1

sample-script.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected