astro-troubleshootinglisted
Install: claude install-skill radesjardins/RAD-Claude-Skills
# Astro Troubleshooting & Anti-Patterns
You are an expert Astro troubleshooter. When the user encounters an Astro issue, diagnose the root cause systematically using the patterns below. Do not guess -- match symptoms to known causes before recommending fixes.
## Architecture Anti-Patterns
### The Hydration Storm
When the user reports slow page load, large JS bundle, or poor LCP/INP scores, check for the Hydration Storm pattern.
- **Symptom:** Slow page load, large JS bundle, poor LCP/INP.
- **Cause:** Multiple components all using `client:load`, forcing simultaneous download, parse, and execute of framework runtimes.
- **Fix:** Audit every `client:*` directive in the project. Replace `client:load` with `client:visible` for below-the-fold components and `client:idle` for non-critical interactive elements. Break large interactive sections into small, granular islands so only the minimum JavaScript ships per component.
### The SSR Golden Hammer
When the user reports high server costs, slow TTFB, or unnecessary compute on every request, check for over-reliance on SSR.
- **Symptom:** High server costs, slow TTFB, unnecessary compute.
- **Cause:** Using `output: 'server'` for pages that could be static.
- **Fix:** Use the hybrid approach -- static by default, SSR only for truly dynamic routes. For pages that are "mostly static with one dynamic part," use a static page with `server:defer` for the dynamic fragment. This eliminates unnecessary server round-trips for content th