Apps

Web app

The React 19 + Vite + Mapbox SPA in apps/web.

The web app is a single-page application built with React 19, Vite 8, and Mapbox GL 3.

Structure

apps/web/
├── src/
│   ├── components/    # Map, sidebar, controls
│   ├── routes/        # TanStack Router routes
│   ├── lib/           # Web-specific glue
│   ├── hooks/         # React hooks
│   └── main.tsx       # Entry
├── public/            # Static assets
├── nginx.conf         # Production server config
├── entrypoint.sh      # Runtime env injection
├── Dockerfile         # Multi-stage build → nginx
└── vite.config.ts

Key dependencies

LibraryWhy
mapbox-gl + react-map-glThe map
@tanstack/react-routerType-safe routing with code-split routes
@tanstack/react-queryServer state caching
zustandClient state (from @routess/core)
tailwindcss v4Styling, themed via @routess/design-tokens
@radix-ui/*Headless UI primitives
@react-oauth/googleGoogle sign-in button

Runtime configuration

The Dockerfile builds with placeholder values. At container start, entrypoint.sh substitutes the real values from environment variables into the built JS files. This lets one image be promoted across environments without rebuilding.

Scripts

bun run dev              # Vite dev server
bun run build            # Production build
bun run preview          # Preview the production build locally
bun run test             # bun test + happy-dom
bun run check-types      # tsc --noEmit

On this page