0
0
Blockchain / Solidityprogramming~10 mins

Development tools setup (Hardhat, Remix) in Blockchain / Solidity - Step-by-Step Execution

Choose your learning style9 modes available
Concept Flow - Development tools setup (Hardhat, Remix)
Start
Choose Tool
Hardhat
Install
Configure
Compile & Test
Deploy
End
This flow shows choosing between Hardhat or Remix, then installing or opening, configuring, compiling/testing, and finally deploying smart contracts.
Execution Sample
Blockchain / Solidity
npm init -y
npm install --save-dev hardhat
npx hardhat
// Follow prompts to create project
// Write contract in contracts/ folder
npx hardhat compile
npx hardhat test
This code sets up a Hardhat project, compiles contracts, and runs tests.
Execution Table
StepActionToolResultNotes
1Initialize npm projectHardhatpackage.json createdSets up Node.js project
2Install HardhatHardhatHardhat installedAdds Hardhat to project dependencies
3Run Hardhat setupHardhatProject scaffold createdIncludes config and sample contract
4Write smart contractHardhatContract file createdIn contracts/ folder
5Compile contractsHardhatContracts compiledCheck for errors
6Run testsHardhatTests executedVerify contract behavior
7Open Remix in browserRemixIDE loadedNo install needed
8Write contract in RemixRemixContract code readyIn browser editor
9Compile contractRemixContract compiledInstant feedback
10Deploy contractRemixContract deployedUsing injected Web3 or local node
11End--Setup complete
💡 Setup and initial contract deployment completed using chosen tool
Variable Tracker
VariableStartAfter Step 3After Step 5After Step 6After Step 10Final
npm projectnonepackage.json createdpackage.json + hardhat configpackage.json + compiled contractspackage.json + tests passedproject ready
Hardhat installednoyesyesyesyesyes
Remix IDEclosedclosedclosedclosedopenopen
Contract codenonesample createdcompiledtesteddeployeddeployed
Key Moments - 3 Insights
Why do we run 'npm init' before installing Hardhat?
Because 'npm init' creates a package.json file which is needed to manage project dependencies like Hardhat, as shown in execution_table step 1.
Can we use Remix without installing anything on our computer?
Yes, Remix runs in the browser directly, so no installation is needed, as shown in execution_table step 7.
Why do we compile contracts before testing or deploying?
Compiling checks for errors and creates files needed for testing and deployment, as shown in execution_table step 5.
Visual Quiz - 3 Questions
Test your understanding
Look at the execution_table, at which step is the Hardhat project scaffold created?
AStep 3
BStep 5
CStep 2
DStep 7
💡 Hint
Check the 'Result' column for 'Project scaffold created' in execution_table
According to variable_tracker, what is the state of 'Contract code' after Step 6?
Acompiled
Btested
Cnone
Ddeployed
💡 Hint
Look at the 'Contract code' row and the 'After Step 6' column in variable_tracker
If you want to avoid installing anything locally, which tool and step should you use?
AHardhat, Step 2
BHardhat, Step 3
CRemix, Step 7
DRemix, Step 10
💡 Hint
Refer to execution_table step 7 where Remix IDE is opened in browser without install
Concept Snapshot
Development tools setup for blockchain:
- Hardhat: install via npm, init project, write, compile, test, deploy
- Remix: browser IDE, write, compile, deploy without install
- Compile before testing or deploying
- npm init creates project config
- Choose tool based on preference and setup needs
Full Transcript
This visual guide shows how to set up blockchain development tools Hardhat and Remix. First, you choose your tool. For Hardhat, you initialize a Node.js project with 'npm init', install Hardhat, and run its setup to create a project scaffold. Then you write smart contracts, compile them to check for errors, and run tests to verify behavior before deploying. For Remix, you open the browser IDE, write your contract code, compile instantly, and deploy using a connected wallet or local node. The execution table traces each step with results, and the variable tracker shows how project files and states change. Key moments clarify why npm init is needed, how Remix requires no install, and why compiling is essential before testing or deploying. The quiz tests understanding of steps and tool differences. This setup is the first step to building blockchain apps.