Installation
CLI only (no config required)
Run astro-doctor without installing it at all:
pnpm dlx @santi020k/astro-doctor@latestnpx @santi020k/astro-doctor@latestyarn dlx @santi020k/astro-doctor@latestbunx @santi020k/astro-doctor@latestThis scans the current directory and prints a health report with score.
Install as a dev dependency
Add to your project so it's always available and pinned to a version:
pnpm add -D @santi020k/astro-doctornpm install --save-dev @santi020k/astro-doctoryarn add -D @santi020k/astro-doctorbun add -D @santi020k/astro-doctorVS Code Extension (Editor Integration)
For the best experience in VS Code or Cursor, install the official Astro Doctor extension from theMarketplace:
ext install santi020k.vscode-astro-doctorThis provides live diagnostics, hovers, quick fixes, and a visual health score sidebar. SeeVS Code Extension for full features.
ESLint plugin (Standalone or alternative editor integration)
For live in-editor diagnostics (VS Code, Neovim, WebStorm, etc.), install the ESLint plugin and add it to your flat config:
pnpm add -D @santi020k/eslint-plugin-astro-doctor astro-eslint-parsernpm install --save-dev @santi020k/eslint-plugin-astro-doctor astro-eslint-parseryarn add -D @santi020k/eslint-plugin-astro-doctor astro-eslint-parserbun add -D @santi020k/eslint-plugin-astro-doctor astro-eslint-parser// eslint.config.js
import astroDoctorPlugin from '@santi020k/eslint-plugin-astro-doctor'
export default [
astroDoctorPlugin.configs.recommended,
// Add your other config here
]The recommended config includes astro-eslint-parser as the parser for*.astro files and enables all rules at their default severities.
Agent skills
To install the AI agent skills into your project (so Claude, Cursor, and Copilot Workspace know the rules and how to fix them):
astro-doctor installThis copies three skill files to .agents/skills/ in your project root.
GitHub Action
See GitHub Action for full setup instructions. No extra installation is required — the action runs astro-doctor internally.
Works alongside eslint-plugin-astro
astro-doctor is designed to complementeslint-plugin-astro(the official community plugin), not replace it. The two cover different ground:
| Coverage area | eslint-plugin-astro | astro-doctor |
|---|---|---|
| Syntax correctness | ✅ | — |
| Astro Doctor accessibility rules | ✅ | Focused subset |
| Performance (client directives, images, scripts) | — | ✅ |
Security (set:html) | ✅ | ✅ |
Best practices (class:list, env vars) | Partial | ✅ |
| CLI health score + CI reports | — | ✅ |
| AI agent skills | — | ✅ |
If you already use eslint-plugin-astro (e.g. viaeslint-config-basic), add astro-doctor on top for performance scanning, health scoring, and AI context.