Skip to main content
Joshua Foster
Back to selected work
2023 — PresentSoftware Developer · BDOOngoing

BDO: React Design System & Frontend Tooling

Scaling a React design system to 70+ developers across 10 teams while cutting bugs by 73%

Led frontend stack modernisation onto TypeScript, Vite, and Playwright at BDO, architected a shared React design system across 10 product teams, and built Node token-lint checks and pnpm worktree workflows for AI-assisted development.

ReactTypeScriptViteTailwind CSSPlaywrightVitestpnpmNode.js
BDO: React Design System & Frontend Tooling
Interactive Architecture Preview
node scripts/check-tailwind-tokens.mjs
70+ devs · 10 teams
TypeScript + Vite + Playwright + pnpm worktrees-73% bugs · 3× velocity
Interactive architecture & workflow preview

Context

When I joined BDO, frontend delivery was spread across multiple teams working on legacy tooling with inconsistent UI primitives, slow build pipelines, and manual regression checks. Every new feature carried unnecessary bundle weight and required engineers to re-solve layout, accessibility, and state patterns from scratch.

As AI coding agents became part of our daily workflow, a second challenge emerged: agents could generate React components rapidly, but they frequently invented plausible-looking Tailwind classes or bypassed design tokens, causing silent styling drift unless caught before merge.

What I Built & Led

1. Stack Modernisation & Bundle Optimisation

I led the migration of our frontend stack onto TypeScript, Vite, and Playwright, pairing strict type boundaries with automated end-to-end verification:

  • 73% bug reduction alongside faster release cycles across consumer applications.
  • 45% smaller component library bundle through cleaner module boundaries and tree-shakeable exports.
  • Up to 83% reduction in initial entry JavaScript for consumer projects and up to 70% faster UI build times.

2. React Design System for 70+ Developers

I architected and scaled a shared React design system adopted by 70+ developers across 10 teams, tripling delivery velocity through full-stack enablement.

Alongside the code, I mentored engineers on React and TypeScript patterns (cutting onboarding time to effective contribution by two weeks) and organised internal engineering sessions covering Python, Containers, and AI agents.

3. Guardrails & Workflows for AI-Assisted Development

To make AI-assisted engineering reliable in a large multi-team codebase, I built both the static guardrails and the workspace ergonomics around our frontend repos:

  • Tailwind Design Token Lint Scripts: Created Node helper scripts wired into lint checks to catch invalid or hallucinated Tailwind design tokens written by agents before code review.
  • Agent-Based UI & DX Skills: Developed reusable agent skills to assist with UI reviews, developer experience checks, and automated bug hunting.
  • pnpm + Git Worktrees: Migrated projects to pnpm specifically to take advantage of hard-linked stores and faster installs when running multiple AI agents concurrently across separate git worktree branches.
  • Event-Driven AI UIs: Designed event-driven frontend architectures for real-time AI workflows where streaming state, partial tool progress, and user intervention all stay responsive.

Key Decisions

Architectural trade-offs and engineering rationale
Decision AxisChosen PathRejected AlternativeWhy It Matters
Frontend Build & Test BaselineTypeScript + Vite + PlaywrightLegacy bundler + manual QA passesCut UI build times by up to 70%, slashed entry JS by up to 83%, and reduced production bugs by 73%.
Package Manager for Agent Workflowspnpm + git worktreesSeparate npm clones / single branchContent-addressable store makes spinning up isolated worktrees for concurrent agents fast and disk-efficient.
Token Enforcement for Agent CodeNode lint helper scripts in CIDesign system docs + PR commentsFlags invalid Tailwind design tokens generated by agents immediately at lint time.

Outcome

Across 10 teams, the combination of a shared React design system, Vite/TypeScript performance budgets, automated Playwright coverage, and agent-aware lint tooling tripled delivery velocity, cut bug rates by 73%, and reduced new-engineer onboarding time by two weeks.