Skip to content

Set up a simple Hardhat project structure, add a contract with a state variable and a function to modify it.

Notifications You must be signed in to change notification settings

AdrianGeorgeM/Hardhat-Modify-Contract-State

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Modifying State Variables BY: Set up a simple Hardhat project structure, add a contract with a state variable and a function to modify it. And then write a quick test to make sure the function modifies the state variable as expected.

In your project root folder, run npx hardhat test

Extra Challenges: Create a new type string state variable and modify it Change the constructor argument Add a new test Create a scripts directory, deploy your contract and change the contract state