AGENTS.md@preview · git:20260816.95cb545 · 2026-08-16 · sha256 57208d6104cc0374
AGENTS.md@preview git:20260816.95cb545A
Immutable. This exact content is served forever at /api/v1/blob/57208d6104cc0374.
# AGENTS.md - preview/ ## OVERVIEW Browser-only harness for inspecting app UI with Tauri APIs shimmed. The root path can proxy live daemon calls; `/preview/` uses fixtures for page-detail citation states. ## WHERE TO LOOK | Task | Location | Notes | | --- | --- | --- | | Add preview state | `fixtures.ts` | keep shapes aligned with `src/lib/tauri.ts` | | Change preview UI | `main.tsx` | fixture selectors and theme toggle live here | | Mock Tauri invoke | `mocks/core.ts` | fixture mode switch plus live daemon fallback | | Live app preview | `mocks/live-invoke.ts` | proxies daemon calls through `/daemon` | | Vite aliases | `../vite.preview.config.ts` | plugin API shims and port `1421` | ## CONVENTIONS - Run with `pnpm exec vite --config vite.preview.config.ts`. - Use `/preview/` for deterministic fixture states; use `/` only when a live daemon on `:7878` is part of the check. - Keep fixture command responses shaped like the real Tauri wrappers consume. - Add mocks in `mocks/core.ts` only for commands the preview actually renders. - Preserve the page-detail citation variants unless the corresponding UI states are removed from the product. ## ANTI-PATTERNS - Do not let fixture data drift into product code. - Do not make preview-only commands look like validated backend behavior. - Do not add network calls to fixture mode; use the live root path for that. - Do not ignore console warnings for unmocked invokes when adding UI surfaces. ## COMMANDS ```bash pnpm exec vite --config vite.preview.config.ts ```