Code Monkey home page Code Monkey logo

psyoptions-frontend's Introduction

Configuring the app for local development:

Copy .env-example and rename it .env.

OR run touch .env and add the following lines to it:

DEVNET_PROGRAM_ID=GDvqQy3FkDB2wyNwgZGp5YkmRMUmWbhNNWDMYKbLSZ5N
DEVNET_DEX_PROGRAM_ID=DESVgJVGajEgKGXhb6XmqDHGz3VjdgP7rEVESBgxmroY
GRAPHQL_URL=http://localhost:8080/v1/graphql
APP_ENABLED=true

Development

We aim to make development setup as easy as possible. Follow the steps below:

  1. Run npm run wholeShebang
    • This will run a few scripts to run a local Solana network, airdrop SOL to your wallet, create and airdrop SPL tokens to your wallet, deploy PsyOptions, deploy Serum, and create an example PsyOptions market with a Serum market attached.
  2. Run npm run start
    • This will run the local UI server

Extracting market meta data

./node_modules/ts-node/dist/bin.js scripts/extractMetaDataFromMarkets.ts --rpc-url http://localhost:8899 --psyoption-program-id LOCAL_PROGRAM_ID --dex-program-id LOCAL_DEX_PROGRAM_ID --mint1-address MINT1_ADDRESS --mint2-address MINT2_ADDRESS

Deploying the app to dev and prod:

See Deploy Docs

Troubleshooting

If a build fails in google cloud, you can run npm run build-docker locally to simulate a cloud build and debug errors.

psyoptions-frontend's People

Contributors

danmatuszak avatar evanpipta avatar samaugust avatar taylor123 avatar tomjohn1028 avatar

Watchers

 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.