Code repo for week 4 group project
Added Dockerfile and devcontainer.
After reopening in devcontainer, do npm install
in /backend
In /frontend, do:
yarn add --dev husky
yarn install
- Start by running in terminal:
npm run start:dev
.
- Start by running in terminal:
yarn start
.
This code uses the NestJS config mode to load e.g. EndpointRpcUrl and PRIVATE KEY. Explanations for this mode see: https://github.com/Encode-Club-Solidity-Bootcamp/Lesson-15?tab=readme-ov-file#using-nestjs-configurations-module
The code combines RPC URL and API KEY from .env file for Infura (in this case) to RpcEndpointUrl (see backend > app.service.ts). The classical load form env w/ dotenv is still in the code though.
Syntax info for RpcEndpointUrl from env:
INFURA_RPC_URL="https://sepolia.infura.io/v3/" + INFURA_API_KEY="API-KEY"