In the root folder of the project, run the following command
npm i
Then move to the truffle folder and repeat this process
cd src
cd truffle
npm i
Run Ganache on http://localhost:7545 and write in the truffle folder the following command to build the contracts
npx truffle migrate
In the root folder, type the following command
npm run start
Don't forget to import at least two accounts to metamask to test the dapp. Good luck!
- Register or login to infura.io and create a new project, then get the rinkeby url like this > https://ropsten.infura.io/v3/YOUR-PROJECT-ID
- Sign up or log in to Metamask Chrome extension and get your mnemonic.
- Configure these values in the truffle-config.js file.
- On your console, go to the truffle folder and run the following command:
npx truffle deploy --network rinkeby
- Finally, deploy your reactjs app to vercel eg.