Errors
Vite, Vitest, and Astro error fix prompts ready to paste into your AI coding agent.
- astro 2026-05-08
Astro site/base mismatch: links 404 in production but work locally
Astro site/base mismatch — links work locally, 404 in production
Astro site/base config mismatches break absolute internal links in production. Cloudflare Pages root deploy vs subpath deploys. Fix prompt for AI agents.
- vite 2026-05-08
Cannot find module '<package>' or its corresponding type declarations
Cannot find module — Vite + TypeScript module resolution
Vite + TypeScript "Cannot find module" errors. Common causes (missing types, alias misconfig, monorepo) and an AI fix prompt for Claude, Codex, Cursor.
- vite 2026-06-14
Error: Cannot find module @rollup/rollup-linux-x64-gnu
Cannot find module @rollup/rollup-linux-x64-gnu — Vite/Rollup native binary
Vite "Cannot find module @rollup/rollup-linux-x64-gnu/-musl" in Docker or CI. The npm optional-dependency bug, why it happens, and a copy-able fix prompt.
- vite 2026-05-08
Failed to resolve import "<path>" from "<file>". Does the file exist?
Failed to resolve import — Vite import path resolution
Vite "Failed to resolve import" errors. Causes (extension missing, alias broken, file moved, case-sensitivity) and a copy-able fix prompt for AI coding agents.
- vite 2026-06-14
sh: vite: command not found
vite: command not found — missing Vite binary in scripts, Docker, or CI
Fix "vite: command not found" / "sh: vite: not found" in npm scripts, Docker, and CI. Causes (no install, PATH, global vs local) and a copy-able fix prompt.
- vite 2026-05-08
Vite build error: production build fails after dev server runs fine
Vite build error — production-only failures and rollup misalignment
Vite production builds fail when dev works: rollup vs esbuild differences, dead-code-elim drops, peer-dep version skew. Diagnostic prompt for AI agents.
- vitest 2026-05-08
Cannot find package '<package>' imported from <test-file>
Cannot find package — Vitest ESM module resolution
Vitest "Cannot find package" errors. ESM resolution differs from runtime; fix with deps.optimizer or test-environment imports. AI fix prompt included.