Skip to content

Latest commit

 

History

History
106 lines (68 loc) · 1.67 KB

SETUP.md

File metadata and controls

106 lines (68 loc) · 1.67 KB

Requirements

  • Node 14.x+ (or nvm)
  • Yarn
  • PostgreSQL (or docker)

Developer Setup

  • From root project directory, install dependencies:

    yarn
  • Copy testrunner/example.env to testrunner/.env and update according to your local configuration.

  • Run a local instance of the test runner:

    yarn testrunner dev
  • Copy server/example.env to server/.env and update according to your local configuration.

  • Initialize the database:

    yarn server prisma db push
  • Run a local instance of the backend:

    yarn server dev
  • Copy client/example.env to client/.env and update according to your local configuration.

  • Launch snowpack dev server:

    yarn client dev

Dev Tools

Altair GraphQL playground

GraphQL client IDE

  • While client + backend dev servers are running, visit: http://localhost:3000/altair

Prisma Studio

ORM Database Admininistration

  • Run:

    yarn server prisma studio
  • Then visit http://localhost:5555

React Cosmos

Develop UI components in isolation

  • While the client dev server is running:

    yarn client cosmos
  • Then visit http://localhost:5000

Global Scripts

  • Run eslint/prettier across all workspaces:

    yarn lint
    # or
    yarn lint:fix
  • Build all workspaces:

    yarn build
  • Use yarn (testrunner|server|client) [command] to execute yarn commands in a workspace:

    yarn testrunner
    yarn server
    yarn client