Skip to content

AugurProject/augur-forkwatch-website

Repository files navigation

ForkWatch

Source for the ForkWatch website.

The site is a static Astro + React frontend for Augur fork safety content, REP holder checks, and migration progress data generated from Ethereum mainnet reads.

Stack

  • Astro 6 with selective React islands
  • React 19 for interactive components
  • Tailwind CSS 4 via the Vite plugin and CSS-first styles
  • Biome for linting and formatting
  • TypeScript for app and script code
  • Vitest for unit tests
  • viem for Ethereum reads
  • Bun for package management and scripts
  • GitHub Actions + GitHub Pages for production deployment

Repository Layout

src/
├── components/          # Astro + React UI components
├── content/             # Fork page copy and resources
├── domain/              # Ethereum, migration, and token constants
├── features/            # Migration progress and REP checker feature code
├── layouts/             # Astro layouts
├── lib/                 # Shared utilities
├── pages/               # Astro routes
├── services/            # Ethereum read helpers
└── styles/              # Global Tailwind CSS

scripts/
├── generate-migration-progress.ts
└── validate-migration-progress.ts

public/
└── data/migration-progress.json

Development

Prerequisites

  • Bun 1.3.x, matching CI
  • Node.js compatible with the installed Astro/TypeScript toolchain

Setup

bun install --frozen-lockfile

Commands

Command Purpose
bun run dev Start Astro dev server at localhost:4321
bun run typecheck Run Astro/TypeScript checks
bun run lint Run Biome checks
bun run test Run Vitest tests
bun run build Build the static site
bun run generate:migration-progress Generate public/data/migration-progress.json
bun run validate:data Validate migration progress JSON
bun run preview Build then preview the site
bun run format Run Biome with writes enabled
bun run check Run typecheck, lint, tests, and data validation

Before declaring work done, run:

bun run check
bun run build

Configuration

Astro builds static output and uses GitHub Pages defaults when:

  • GITHUB_PAGES=true

Production metadata and paths can be overridden with:

  • SITE_URL
  • BASE_PATH
  • PUBLIC_MAIN_SITE_URL

Migration data generation can use:

  • ETH_RPC_URL for server-side RPC reads
  • ETH_RPC_LABEL for a public-safe source label

Never expose private RPC URLs through PUBLIC_* environment variables.

Fork Safety Scope

ForkWatch does not:

  • connect wallets
  • request signatures
  • send transactions
  • ask for private keys, seed phrases, or recovery words
  • check exchanges, custodians, L2s, or bridges
  • prove that every address a user controls has been checked

The REP checker sends the public address entered by the user to public Ethereum RPC providers from the browser.

Migration Data

Migration progress is generated by scripts/generate-migration-progress.ts and committed at public/data/migration-progress.json.

Pull requests validate committed data. Scheduled and main-branch workflow runs regenerate the data before building.

Styling

Tailwind is configured through the Vite plugin and the global stylesheet at src/styles/global.css.

Biome is configured in biome.json.

CI/CD

deploy-pages.yml runs on:

  • hourly schedule
  • pushes
  • pull requests
  • manual workflow dispatch

The workflow:

  1. Installs dependencies with Bun.
  2. Generates migration progress outside pull requests.
  3. Validates committed migration data on pull requests.
  4. Runs typecheck, lint, tests, data validation, and build.
  5. Verifies the static output.
  6. Deploys to GitHub Pages from the repository default branch.

Worktrees

Use raw Git worktrees under .worktrees/ when parallel branch checkouts are useful:

git fetch origin
git worktree add -b feature/example .worktrees/feature-example origin/main

Remove when done:

git worktree remove .worktrees/feature-example
git worktree prune

Releases

No releases published

Packages

 
 
 

Contributors