diff --git a/step01_hardhat_typescript_helloworld/README.md b/step01_hardhat_typescript_helloworld/README.md index f67c3ca..a09e1f8 100644 --- a/step01_hardhat_typescript_helloworld/README.md +++ b/step01_hardhat_typescript_helloworld/README.md @@ -6,10 +6,12 @@ Note: You can use this prebuilt [template project](https://github.com/paulrberg/ Copy the files from step00_hardhat_helloworld +``` npm install --save-dev ts-node typescript - +``` +``` npm install --save-dev chai @types/node @types/mocha @types/chai - +``` rename your config file to hardhat.config.ts We need to apply three changes to your config for it to work with TypeScript: @@ -21,17 +23,19 @@ We need to apply three changes to your config for it to work with TypeScript: For updating test and scripts [follow this](https://hardhat.org/guides/typescript.html#writing-tests-and-scripts-in-typescript) For Type-safe smart contract interactions: - +``` npm install --save-dev typechain @typechain/hardhat @typechain/ethers-v5 - +``` Update tsconfig.json - +``` tsc - +``` +``` npx hardhat compile - +``` +``` npx hardhat test - +``` @@ -51,22 +55,30 @@ npx hardhat help -------------------------------------- For Fresh project follow these steps: -------------------------------------- - +``` npm init - +``` +``` npm install --save-dev hardhat - +``` +``` npx hardaht +``` Select an Advance sample project .... - +``` npm install --save-dev "hardhat@^2.8.2" "@nomiclabs/hardhat-waffle@^2.0.0" "ethereum-waffle@^3.0.0" "chai@^4.2.0" "ethers@^5.0.0" "solhint@^3.3.6" "solidity- coverage@^0.7.16" "@typechain/ethers-v5@^7.0.1" "@typechain/hardhat@^2.3.0" "@typescript-eslint/eslint-plugin@^4.29.1" "@typescript-eslint/parser@^4 - +``` +``` npm install dotenv - +``` +``` npm install --save-dev ts-node - +``` +``` npm install @nomiclabs/hardhat-etherscan - +``` +``` npm install hardhat-gas-reporter +```