Getting started
Install the workspace, configure an app, run it, and check your changes.
Prerequisites
| Tool | Version | Used by |
|---|---|---|
| pnpm | 10.26.x | Workspace installs and scripts |
| Node.js | 20.9+ | Next.js and repository scripts |
| Bun | 1.4+ | Docs and Expo scripts |
| Go | 1.25+ | apps/api |
| Docker | Current | Local Postgres and parity checks |
Install dependencies once from the repository root:
pnpm installConfigure an app
Copy only the environment files you need:
cp apps/web/.env.example apps/web/.env.local
cp apps/api/.env.example apps/api/.env
cp apps/expo/.env.example apps/expo/.env.localThe web app and API require DATABASE_URL. Web and Expo also need the public
Supabase URL and anonymous key for authentication.
Start local Postgres when you need repository data:
pnpm db:dev:up
pnpm db:dev:psqlpnpm db:dev:reset deletes the local database volume and reloads it.
Run an app
pnpm dev # web
pnpm dev:docs
pnpm dev:api
pnpm dev:expoRun each app in its own terminal. Use node packages/statshub-tooling/apps.cjs
for addresses reachable from another device. Use pnpm phone for the Expo dev
client.
Check changes
pnpm checkpnpm check runs each workspace's lint, typecheck, and test tasks through
Turbo. Also run the app-specific build or export for the area you changed:
pnpm build:docs
pnpm --dir apps/expo exec expo export --platform ios
pnpm buildThe docs build validates icons. Docs lint also validates internal links:
pnpm --filter statshub-docs lint