Building FieldDojo
FieldDojo is a calculator app for people who carry tools. Construction, HVAC, electrical, and plumbing pros need numbers fast, in the field, usually without signal — and they need to defend those numbers to an inspector later. It's offline-first, code-aware, and built to use one-handed. Live on the App Store now, with Android in review on Google Play. Still shipping new calculators weekly.
Get FieldDojo on the App Store → Android is in review on Google Play, live soon.
Why I built it
Every trade has the same three problems on the jobsite: you need a calculation, you need the code reference behind it, and you need a record of what you ran two days ago when the inspector asks. The usual toolkit for that is a generic calculator app, a paper formula card taped to the truck dashboard, and a PDF of the NEC nobody can search on a 5-inch screen with gloves on.
So I built FieldDojo as one app that runs the calculation, shows the formula and the code reference, saves history per project, and exports a clean PDF or a quick text summary for the office — all with no network connection.
What it does
Calculators that show their work
Every FieldDojo calculator does three things at once: it gives you the answer, it shows the formula, and it cites the governing code. Run a voltage drop calculation and you get the result, the Vd = 2 × K × I × L / CM derivation, and a badge linking to NEC 310.16. Run a BTU load and you get the ACCA Manual J reference. Run a pipe sizing calculation and you get the IPC E103.3 badge.
A generic calculator gives you the number and nothing else. On a jobsite the number has to hold up when an inspector or a GC asks where it came from, so every result here carries its formula and its code section with it.
Four trades, one app
FieldDojo ships calculators for the four trades I work around most:
- Construction: concrete volume, board feet, stud count, drywall sheets, roofing squares, paint coverage
- HVAC: BTU load (Manual J–style), duct sizing, refrigerant charge, air changes per hour
- Electrical: wire gauge, voltage drop, conduit fill, load calculation
- Plumbing: pipe sizing, flow rate, drainage slope, water heater sizing, fixture-unit lookups
Each trade gets its own color accent (orange for construction, cyan for HVAC, blue for electrical, emerald for plumbing) so you know what mode you're in at a glance. Imperial and metric both work, one tap to switch.




Offline-first project grouping
Every calculation saves to local SQLite history, scoped to the project you're on. Switch projects from the calculator screen and only that project's history shows. When connectivity returns, a sync engine pushes the local queue to the backend with exponential backoff and server-wins conflict resolution. Run calculations all day in a basement with no signal; everything lands in the cloud the moment the phone sees Wi-Fi.
Material cost estimates
Tap any result and FieldDojo adds a material cost estimate — concrete by the cubic yard at regional pricing, copper by the foot, refrigerant by the pound, drywall by the sheet. The cost data is curated, ships with the app, and tunes per region. It's not a quoting tool, it's a sanity check before you commit to a supply run.
Export to PDF or text in one tap
Any calculation exports as a branded PDF or shares as plain text through the native share sheet. The PDF carries the inputs, the formula, the code reference, and the cost estimate, formatted to print clean on one page. Email it to the office, drop it in a project folder, text it to the customer.
Built for one-handed use
Big touch targets, high-contrast result cards, typography that holds up in direct sunlight, haptics on every input. The UI runs on the New Architecture — bridgeless mode, Fabric, Reanimated 4 on the UI thread — so animations stay at 60fps even on older Android phones.
The stack
Tradespeople bet a workday on these answers, so I picked the most predictable stack I know.
Mobile — Expo SDK 55 + React Native 0.83
The whole app runs on the New Architecture: bridgeless mode, Fabric renderer, TurboModules, Hermes. Startup skips the old bridge tax entirely, and animations stay on the UI thread thanks to react-native-reanimated 4 and react-native-worklets.
Routing is Expo Router with NativeTabs — each trade is its own tab with a stack inside. State is Jotai for UI and TanStack Query for server state, with API hooks generated from the backend's OpenAPI spec via Orval, so a backend change rebuilds the typed client automatically. Styling is NativeWind v5 + Tailwind v4 with custom CSS-wrapped primitives; trade colors, typography, and spacing tokens all live in global.css.
Local storage — op-sqlite + Drizzle + MMKV
History lives in op-sqlite with Drizzle ORM for type-safe queries and migrations. Preferences (unit system, default trade, onboarding state) sit in MMKV for instant synchronous reads. A one-time migration moves legacy MMKV history into SQLite on first launch, so nobody loses data on upgrade.
Backend — Hono + Drizzle + Postgres
The API is Hono with OpenAPI 3.0 + Zod, serving an interactive Scalar UI at /reference and a JSON spec at /doc. Every route is typed end to end — Zod schema, AppRouteHandler handlers, tests through Hono's testClient.
Auth is Better-Auth with email/password, anonymous-session, and Expo plugins. Anonymous users get a real session on first launch, so their offline calculations sync the instant they create an account — and account linking moves the local history over without dropping a single calculation. The database is self-hosted Postgres with Drizzle migrations and a backup pipeline to Backblaze B2. Logging is Pino with request IDs and structured fields.
Marketing site — Astro 6
The site you're reading. Astro 6, config-driven, blog content collections, JSON-LD for posts, and an llms.txt for AI crawlers. Deploys go to Vercel, with a Dockerfile fallback that self-hosts the same build. Sitemap, RSS, and per-page SEO metadata run through a vendored Astro integration.
Crash reporting + analytics
Sentry for crashes (with proper Hermes source maps), Firebase Analytics for product metrics, RevenueCat for the paid tier. The analytics layer sits behind an abstraction, so swapping providers later is a one-day job, not a rewrite.
The knowledge base that compounds
One thing FieldDojo has that most apps don't: a structured knowledge base of trade domain knowledge. The wiki/ directory holds pages on building codes, engineering formulas, material properties, and field practices — and I maintain it with an LLM-assisted workflow as I add calculators or ingest new code references.
When a new reference lands (a new IRC chapter, an ACCA Manual J update, a regional code amendment), it gets synthesized into the wiki, the index updates, and any calculators that should change get flagged. The wiki is also the grounding source the next calculator is built against, so each feature ships with deeper code awareness than the last. The accuracy compounds over time instead of drifting — it's the part of this project I'm most proud of.
What's coming
FieldDojo shipped on the App Store; Android's clearing review now. Development doesn't stop — the roadmap:
- More calculators — solar (string sizing, inverter ratios), refrigeration (cooling load with humidity), framing (header sizing per IRC R602), gas piping (pressure drop per NFPA 54). Each one ships with a wiki page explaining the formula and citing the code.
- Project photos and notes — attach photos and freeform notes to a project, included inline in the PDF export so the inspector or customer gets the full picture in one document.
- Inspector mode — a read-only, single-project share link that expires after 30 days. Give an inspector everything they need without granting an account.
- Office accounts — admin views for shops with multiple field techs: every project, every tech's calculations, every PDF, in one dashboard. Field techs keep working exactly as they do today.
- Photo-to-estimate — snap a job site or upload a sketch and get a calculation breakdown: concrete volumes from a foundation drawing, wire runs from a rough plan, BTU loads from a floorplan. Grounded against the wiki, so the math stays code-aware.
Who it's for
Independent contractors who'd rather run one app than five. Field techs in HVAC, electrical, and plumbing who need fast, code-aware math on-site. Estimators who want a sanity check before quoting. Apprentices learning the codes, who get the formula and the reference badge with every result.
FieldDojo is being built in public, new calculators and code references every week. If you run trade math more than once a week, download FieldDojo on the App Store — Android's coming once it clears review — and tell me what calculator I should build next.