Most mobile apps start with Figma. They start with the UI, the "feel," and the onboardings. For Nurse Ledger, we did the opposite.
We started with a spreadsheet. Specifically, a spreadsheet of every nursing pay category in the US: night differentials, weekend premiums, charge nurse pay, certification bonuses, travel stipends, PRN waivers, and overtime rules that vary by state (hello, California).
High Precision, Low Drama
A pay calculator is only as good as its last result. If a nurse trusts our app and it gives them a number that's off by $20 on a paycheck, we have lost that user forever. Trust is the only currency here.
That's why Task #1 for Phase 1 was building a logic-only Core Engine. No React Native UI, no Supabase connection, no navigation. Just pure TypeScript functions and a heavy Jest test suite.
The "Blended Rate" Problem
One of the trickiest parts of US nursing pay is the "blended rate." If you earn a base rate of $50, but you have a $2 BSN differential and a $5 weekend premium, your "regular rate" for overtime purposes is $57. California law, in particular, requires overtime to be calculated on this blended rate, not just the base.
Our engine now handles all 14 major pay categories and properly calculates these blended rates across 70+ parameters.
Testing for Truth
We now have 15 core tests passing, covering everything from Sarah's PRN Saturday shift to complex California holiday overtime scenarios.
PASS engine/__tests__/calculate.test.ts
✓ calculates base pay correctly without differentials
✓ calculates base pay + education + certification + role differentials
✓ calculates the exact spec scenario: Sarah PRN Saturday
✓ calculates partial shift time boundaries (evening/night) & holiday multipliers
✓ calculates California overtime utilizing the blended rate
The repo is now connected to GitHub, and CI is being set up. The foundation is set. Now we can start building the UI with the confidence that the math is already "shipped" in our heads.