Git Product home page Git Product logo

nft-marketplace-aptos's Introduction

Demo NFT marketplace

A full stack demo NFT marketplace based on aptos devnet. Aiming for clean and cocise code that is easy to understand and also make some automations to speed up full stack development.

Tech stack

Development

Contract

  • Compile move module

    NAME=<name> ADDRESS=<address> yarn workspace market-contracts move:compile
    
  • Publish move module

    NAME=<name> ADDRESS=<address> yarn workspace market-contracts move:publish
    

Frontend

  • Installation

    yarn workspace market-frontend install
    
  • Config .env.development.local

    In order to expose a variable to the browser you have to prefix the variable with NEXT_PUBLIC_

    NEXT_PUBLIC_NFT_STORAGE_KEY=
    NEXT_PUBLIC_WALLET_PRIVATE_KEY=
    NEXT_PUBLIC_MARKET_ADDRESS=0x64f236ab7ba803a8921c16fa2b9995da51033e3ed2e284e358f0d5431a39c0d0
    NEXT_PUBLIC_MARKET_NAME=_1200_dollars_per_hour
    NEXT_PUBLIC_MARKET_FEE_NUMERATOR=10
    NEXT_PUBLIC_MARKET_INITIAL_FUND=10000
    NEXT_PUBLIC_MARKET_COIN_TYPE=0x1::aptos_coin::AptosCoin
    NEXT_PUBLIC_APTOS_NODE_URL=https://fullnode.devnet.aptoslabs.com/v1/
    NEXT_PUBLIC_APTOS_FAUCET_URL=https://faucet.devnet.aptoslabs.com/v1/
    NEXT_PUBLIC_SUPABASE_KEY=
    NEXT_PUBLIC_SUPABASE_URL=
    

    Read more on https://nextjs.org/docs/basic-features/environment-variables

  • Run script for create market

    NODE_ENV=development yarn workspace market-frontend aptos:create-market
    
  • Run dev

    yarn workspace market-frontend dev
    

Backend

  • Setup

    // install all the dependencies listed within package.json
    yarn workspace market-backend install
    
    // set up a new Prisma project
    yarn workspace market-backend prisma init
    
  • Config .env

    DATABASE_URL=<YOUR SUPABASE DB URL>
    APTOS_NODE_URL=https://fullnode.devnet.aptoslabs.com/v1/
    APTOS_FAUCET_URL=https://faucet.devnet.aptoslabs.com/
    MARKET_ADDRESS=<YOUR MARKET ACCOUNT>
    
  • DB Migration

    // create migrations from your Prisma schema, apply them to the database
    yarn workspace market-backend prisma migrate dev --name <new-file-suffix>
    
  • Run

    yarn workspace market-backend start
    

nft-marketplace-aptos's People

Contributors

suzukidavid avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Forkers

kyungnankim xwhiz

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.