Giter Club home page Giter Club logo

nightmarket-oss's Introduction

Night Market

A Solana NFT marketplace built by the people for the people using open source software by Holaplex, Metaplex and Motley Labs.

Contributing

We welcome contributions to Night Market from the community -- please open a pull request!

Feel free to join the Motley DAO Discord to talk to the team and other community members.

All contributions are automatically licensed under the GPL 3.0.

Overview

Stack overview

This repository contains the Night Market frontend -- a web app built with Next.js, React and TailwindCSS. The main branch is what's deployed at nightmarket.io.

The frontend talks to andromeda, our web2 backend which talks to data providers, and reward-center-program, our marketplace on-chain program.

Code overview

  • src/typings - Types declarations.
  • public/* - Static assets including fonts, images and locales.
  • src/components/* - The different reusable components used throughout the app including Button, Icon, Avatar, Form, List, etc.
  • src/hooks/* - Useful hooks used throughout the app.
  • src/layouts/* - The different layouts used by pages.
  • src/modules/* - Various helper methods and utilities worthy of converting to a helper library.
  • src/pages/* - Contains all the app's pages.
  • src/providers/* - Providers to provide context at various places.
  • src/app.config.ts - Global config values used throughout the app like app's base url, api url, solana rpc url, market's auctionhouse address etc.
  • src/cache.ts - Global reactive variables that can be set and read from anywhere in the application. Similar to redux state.
  • styles/globals.css - A small amount of global styles since the app mostly make use of vanilla Tailwind CSS.
  • next-18next.config.js - Supported languages and the default language.
  • next.config.js - NextJS configuration containing route redirects and other NextJS extensions.

Environment

The list of required environment variables for the application. To be set through the OS environment or through .env file.

Name Description
NEXT_PUBLIC_ADDRESS_LOOKUP_TABLE The address of the reward center's address lookup table generated by reward-center-cli and used for the buy_listing and accept_offer actions.
NEXT_PUBLIC_ANDROMEDA_ENDPOINT The URL of the andromeda deployment. Use https://api.nightmarket.io/api for the production Night Market deployment.
NEXT_PUBLIC_AUCTION_HOUSE_ADDRESS The address of the auction house for the reward center, generated by reward-center-cli.
NEXT_PUBLIC_AUCTION_HOUSE_PROGRAM_ADDRESS Should be set to rwdD3F6CgoCAoVaxcitXAeWRjQdiGc5AVABKCpQSMfd. A deployment of the reward-center-program.
NEXT_PUBLIC_BASE_URL The URL of the andromeda deployment. Use https://api.nightmarket.io for the production Night Market deployment.
NEXT_PUBLIC_BLOCK_REFERRALS true or false. Whether to use the BuddyLink integration.
NEXT_PUBLIC_ORGANIZATION_NAME The BuddyLink organization.
NEXT_PUBLIC_REFERRAL_KEY An API key for the BuddyLink tracking endpoint.
NEXT_PUBLIC_REFERRAL_URL https://market-api.getdolphin.io/apiv3/
NEXT_PUBLIC_SOLANA_RPC_URL A Solana RPC endpoint. E.g. https://api.mainnet-beta.solana.com/

Getting Started

First, install dependencies

yarn install

Then, run the development server:

yarn dev

You might also want to setup a .env.local file to override some ENV variables like RPC provider, don't forget to restart the server if you do.

NEXT_PUBLIC_SOLANA_RPC_URL="https://rpc.helius.xyz/[...api_key]"

Deploy

yarn build
yarn start

nightmarket-oss's People

Contributors

alchemistgo87 avatar dannymanzano172 avatar furkanksl avatar jettlove avatar joshatmotley avatar kespinola avatar kevinrodriguez-io avatar kristianeboe avatar metalgear-dev avatar milorue avatar motleylabs-matt avatar mpwsh avatar nonfungible-dev avatar omarkilani avatar prakhardubey2002 avatar seharlan avatar waggme avatar

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.