$ cat the-stack-i-keep-coming-back-to.md
The stack I keep coming back to.
What I reach for when I start a product today, what I gave up to get it, and the choices I got wrong along the way.
- Published
- 2026
- Reading
- 5 min
- Tags
- engineering · stack
I’ve started enough projects by now to notice I keep ending up in the same place. One early choice I’ve since reversed. One later choice I managed to get wrong twice in a row. We’ll get to both.
So here it is: what I reach for when I start a product today, and what I gave up to get it.
- Language. TypeScript, strict, ESM only. The server turns on the stricter flags too.
- API. Hono, with Zod validating every request.
- Contract. OpenAPI generated from the Zod schemas, and a typed client generated from that.
- Data. Postgres with Drizzle.
- Web. TanStack Start with Router, Query and Form. Tailwind v4 and shadcn/ui.
- Content sites. Astro. You’re looking at one.
- Hosting. Cloudflare Workers for the web apps and sites, Fly.io for the API.
- Tests. Vitest against a real Postgres.
One schema, end to end
If there’s one rule holding the whole thing together, it’s that a shape gets written down once.
A Zod schema validates the request at the edge of the API. That same schema generates the OpenAPI spec, the web app’s types are generated from the spec, and its client calls those types. So when I rename a field, the API, the docs and the browser all refuse to compile until they agree with each other again. Nobody maintains anything by hand, which means nothing gets the chance to drift.
Underneath that sits Drizzle, which is really just typed SQL, and I mean that as a compliment. I picked it over Prisma because it stays closer to the query, the runtime is smaller, and there’s no codegen step to forget about. Postgres does the integrity work - foreign keys, CHECK constraints, partial indexes - since I’d much rather have the database refuse a bad row than trust every caller to behave.
And one more guard on top: apps import from packages and never from each other, and a dependency checker fails the build the moment somebody tries. Somebody being me, or the agent.
Small tools I can read
Hono is small and written in TypeScript; I can open a middleware and know what it does. It also isn’t married to one runtime, so the API can move later without a rewrite.
The choice people raise an eyebrow at is the other one. I call every outside service with plain fetch - the AI providers, Stripe, the bank data, the text messages. No vendor SDKs, and it’s written into the instruction file the agent reads, so it doesn’t helpfully install one for me.
The reasoning goes like this. An SDK is a big dependency that bends my code around one vendor’s idea of what a request looks like. A thin adapter over fetch keeps providers swappable, and puts the retries, timeouts and tracing where I can see them. I keep four AI providers behind one interface, and switching between them is a config change.
Is it free? It surely isn’t. The decision record says it plainly: new provider features don’t show up with an upgrade. Tool use, prompt caching, streaming; every one of those is an adapter change I get to write myself.
The front end
TanStack Start, with Router, Query and Form. One family covers routing, server functions, data fetching and forms, typed all the way down to the route parameters, and I get server rendering when I need it without signing up for Next.js’s conventions on everything else.
Now, full disclosure. The decision record for this one literally says “Rationale not explicitly recorded”, and so does the one for Fly. Past me picked both early, before writing the reason down had become a habit, so the reasons you’re reading are the ones I’d give you today. Not ideal for a guy with 158 decision records.
Styling is Tailwind v4 with the theme in CSS variables, and shadcn/ui for components. The component code is mine, sitting in my repo, so when a design wants something the library never planned for, there’s no library to argue with.
Where it runs
Anything that renders pages goes on Cloudflare Workers: the web app, the marketing site, this site. Cheap, close to whoever is reading, and nothing for me to keep alive.
The API is a long-running Node process that wants to live next to its database, so it’s a Docker image on Fly. Deploys are blue-green and migrations run before the new version takes any traffic, which is exactly why every migration has to work with the code that’s already running.
What I got wrong
Auth first. Decision number seven was WorkOS, and I moved to Clerk. Nothing wrong with WorkOS; its hosted redirect and sealed cookie just didn’t sit well with a web app and an API on separate origins, and Clerk’s components and bearer tokens did.
Then email, which took me three decisions, so settle in. Round one: every message goes through Knock, with Resend behind it, so I can edit templates without a deploy. Sweet idea; never used it once. The templates ended up in the repo and shipped through CI anyway, so I was paying for a second system to do nothing. Round two: send email straight through Resend. Round three: delete email altogether. A text message did the job better, and the mail package was gone.
Tests last. I’ve mocked databases on earlier projects and been burned by it - green tests, then broken constraints in production - so now every test runs against a real Postgres in a container, and auth is the only thing stubbed. What I got wrong this time was the browser suite. I put it in CI as a gate and took it back out a day later, which is where the other post starts.
At the end of the day I used to defend all of this as taste. Strict types, one schema, boundaries a tool enforces, adapters I can actually read. Then an agent started writing most of the code, and every one of those turned out to be a place where its mistake stops at a compile error before it gets anywhere near me. What’s good for an LLM is good for the humans, and vice versa.