GithubHelp home page GithubHelp logo

cuckflong / vertex-web-monorepo-snapshot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from vertex-protocol/vertex-web-monorepo-snapshot

0.0 0.0 0.0 32.14 MB

Public snapshots of Vertex's frontend monorepo

Shell 0.01% JavaScript 0.25% TypeScript 98.09% CSS 1.65%

vertex-web-monorepo-snapshot's Introduction

Vertex Web Monorepo

Getting Started

Public Repo Setup

Public snapshots of the Vertex frontend have the following additional steps:

  • Populate necessary API keys & IDs in sensitiveData.ts for the trade app
  • Obtain a license to TradingView's Advanced Charts and put the build files in public/charting_library. The type declarations have been left as-is for typecheck to work.
  • Optional: Populate the gtmId for marketing sites.

Dependencies

  • Install dependencies using yarn install.
  • For usage of a local Vertex SDK (useful if you're testing SDK changes / unpublished SDK functionality):
    • run yarn link-local in vertex-typescript-sdk,
    • then yarn link-local-sdk in the apps/trade app.

      To reverse this (i.e. unlink packages for remote SDK), run yarn unlink-local-sdk in this apps/trade.

NOTE: Be sure to run yarn build in the SDK repo for latest SDK changes to reflect

Set up environment:

For apps where a .env file is required, there is a .env.local.example file in the root of the app directory. Copy this file to .env.local and fill in the necessary environment variables.

Run

yarn run dev # Runs app at the appropriate port

Other Considerations

[Trade App] Switching Brand

To switch the "brand" of the trade app, use the available options for NEXT_PUBLIC_BRAND_NAME. Unfortunately, Next.js + Tailwind JIT do not trigger full reloads of the Tailwind configuration on changes of .env.local, so you will need to make a dummy code change in tailwind.config.ts for the new brand to take effect. This could be as simple as changing a newline then saving the file.

[Trade App] Run against local nodes / custom contract addresses

  • Switch your .env.local to point to a local deployment: NEXT_PUBLIC_DATA_ENV=local
  • Put the relevant contracts + endpoint info in useBaseVertexClient
  • Update token addresses in tokens.ts for the local environment. All addresses must be lowercase

vertex-web-monorepo-snapshot's People

Contributors

frankfka 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.