Frontend Field Guide

Engineering field notes

Choosing a frontend
for coding agents.

Choose a stack by the changes your agent will make. A clear place to edit, a useful compiler error and a repeatable browser test all help the next change go well.

Find your starting point

What are you building?
Where will people use it?
Suggested starting point

Vanilla TypeScript

For a calculator or a single form, a local value and a DOM event handler can own the whole interaction.

Tradeoff · When several views depend on the same change, you own the work of keeping them in sync.

Framework reference

Where each one fits

These are engineering judgments. Expand a framework to see which decisions it settles for an agent and which ones still need your attention.

React + TypeScript

My default for a dashboard with connected views. Vite handles the build and React Router handles navigation. Give agents one example for forms, state ownership and loading data so every screen follows the same conventions. React guide

Next.js

Useful when a React application benefits from server rendering and integrated routing. Its dev server lets agents inspect errors, logs and routes. Changes still need clear decisions about caching and which code runs in the browser. Next.js agent tools

SvelteKit

Compact components suit a small team maintaining a full app. Give agents access to the Svelte team's current docs and static analysis so they can catch outdated generated patterns. Svelte agent tools

Vue / Nuxt

Vue keeps the template and its behavior together in a single component file. Pick a consistent API style. Consider Nuxt when you also want app-level routing and rendering conventions. Vue guide

Angular

Useful when many contributors or agents need the same conventions. Its CLI and official agent guidance narrow implementation choices, at the cost of more framework concepts to learn. Angular guidance

Astro

Use content pages with focused interactive islands for a publication or catalog. If several islands need to react to every edit, revisit which part of the UI should own that state. Astro islands

Rendering lab

One edit, two views

Select a task. The row and the count both reflect the same selection. A vanilla render function updates existing elements, so the checkbox keeps keyboard focus.

Review checklist0 of 3 ready
Input event → selection → row and count

When to add a store

Keep state local while one control owns it. For shared state, Zustand's vanilla store gives agents named actions and subscriptions. Render once at mount, subscribe, then unsubscribe when the view goes away. Derive counts from the items.

Nano Stores suits independent values. Signals Core tracks linked calculations. jQuery earns its place when an existing app or plugin needs it. Zustand vanilla API

When to add a renderer

For text or a button, update the existing node. If rows move or contain inputs, preserve their identity so selection and focus survive. Standalone lit-html can handle dynamic templates. When agents are inventing rules for mounting, routing and cleanup, consider a framework. Lit templates

What Rust buys you

Leptos gives you signals and keyed lists for targeted updates. Rust's compiler catches ownership and type errors. Compare cold startup and one real interaction on the same device. For heavy calculations, benchmark a Wasm module including data transfer. Leptos book

From browser to desktop

Tauri can bundle a TS or Leptos frontend in a desktop window and run file or database operations in native Rust. Ship per target: Windows installer and WebView2, macOS app bundle, or Linux AppImage. Dioxus is another option for a desktop-first Rust UI. Tauri packaging · Dioxus