leomanza / trust-me-frontend

NCD II Bootcamp - Peer reputation management in decentralized p2p business applications

Home Page:https://trust-me-near.vercel.app/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NEAR NCD Bootcamp - Level 2 :: 1-day course on building full stack dApps on NEAR

This repository contains an implementation of the front-end and NEAR protocolor interaction via RPC API. The smart contract to interact is the one implemented on the NCD Bootcamp - Level 1. TrustMe Smart Contract.

Prerequisites In order to interact with the smart contract, we need it deployed. Once you have it, copy the smart contract account Id that we are going to use on the daap.

Environment Setup

Local Environment Setup

  1. clone this repo locally
git clone https://github.com/leomanza/trust-me-frontend.git
  1. install dependencies
yarn
  1. open next.config.js and set the CONTRACT_ID env variable with the trus-me smart contract account id deployed on prerequisites.
module.exports = {
  reactStrictMode: true,
  env: {
    CONTRACT_ID: 'dev-839242103921-12345'
  }
}
  1. run the development server
npm run dev
# or
yarn dev

DEV Environment Setup

  1. clone this repo locally (skip if already done on local env setup)
git clone ...
  1. install dependencies (skip if already done on local env setup)
yarn
  1. deploy
vercel
  1. add CONTRACT_ID env variable
vercel env add NEXT_PUBLIC_CONTRACT_ID

copy/paste contract account id

DEV Production Setup

  1. clone this repo locally (skip if already done on local/dev env setup)
git clone ... 
  1. install dependencies (skip if already done on local/dev env setup)
yarn 
  1. deploy
vercel --prod
  1. add CONTRACT_ID env variable (skip if already done on dev env setup)
vercel env add NEXT_PUBLIC_CONTRACT_ID

copy/paste contract account id

About

NCD II Bootcamp - Peer reputation management in decentralized p2p business applications

https://trust-me-near.vercel.app/

License:MIT License


Languages

Language:TypeScript 91.4%Language:CSS 8.0%Language:JavaScript 0.6%