Setting things up to write a smart contract
There are plenty of options when it comes to tooling for smart contracts, such as Remix IDE. In this chapter, and throughout the book we’ll use Visual Studio Code, Hardhat, Node.js
, Web3.js
, and Ether.js
.
Here are the basic setups required to write a smart contract using Visual Studio Code, Solidity, Node.js and Hardhat:
- Install Visual Studio Code: Download and install the latest version of Visual Studio Code from the official website.
- Install the Solidity extension: The Solidity Extension provides syntax highlighting and other features for Solidity development. To install the Solidity Extension, open Visual Studio Code, click on the Extensions icon on the left sidebar, search for
Solidity
, and click Install. - Install Node.js and npm:
Node.js
andnpm
are required to install and manage dependencies for Hardhat and other Ethereum development tools. Download and install the latest version ofNode.js
from the official...