Feature · Scoring
Health score
The health score is a single integer from 0 to 100, plus a letter grade, that summarises how healthy a Vue 3 or Nuxt 4 codebase is. It is computed by the free @geoql/vue-doctor and @geoql/nuxt-doctor CLIs on your machine, with no network calls. The same code and ruleset always produce the same number, so teams use it as a CI gate, a trend line, and a quick answer to "is this repo getting better or worse?"
The formula: severity weights with √-decay
Findings are grouped by rule id. Each rule costs its severity weight (error 5, warn 2, info 0.5) on the first occurrence, and every repeat of the same rule costs less: the i-th repeat is multiplied by 1/√(i+1). The score is max(0, round(100 - total penalty)).
This keeps one triaged pattern repeated across 200 files cheap, while ten different error rules cost the full 50 points. The doctor counts distinct problems, not raw lines.
penalty_for_rule = weight × Σ ( 1 / √(i + 1) for i in 0..count-1 )
score = max(0, round(100 - Σ penalty_for_rule))
grade: A 95-100 · B 85-94 · C 70-84 · D 50-69 · F 0-49Six dimension sub-scores
Every rule category maps to one of six dimensions, and each dimension is scored independently with the same formula. A high overall score can still hide a weak dimension, so the JSON report exposes them under score.byDimension.
- performance: performance, template-perf
- correctness: reactivity, composition, template, sfc, vue-builtin, hydration
- security: security
- maintainability: ai-slop, dead-code, build-quality, deps, structure, modules-deps
- nuxt: nitro, seo, cloudflare, server-routes, data-fetching
- design: design
Score one area at a time
Pass --dimension or --category to re-score only the rules in that scope. The printed score then reflects only the in-scope findings, which makes a performance-only or security-only gate a one-flag change.
npx -y @geoql/nuxt-doctor --dimension performance
npx -y @geoql/vue-doctor --category security --format jsonWhy determinism matters
There is no randomness, no timing, and no LLM in the score. That is what makes it safe to cache, diff across commits, and gate merges on. Test, story, and fixture files are reported but excluded from the score by default, so test helpers do not drag down production health. Compare scores within a project over time, not across unrelated projects.