[{"data":1,"prerenderedAt":785,"buildId":786},["ShallowReactive",2],{"-cli-reports":3,"-cli-reports-surround":684,"navigation_docs":695},{"id":4,"title":5,"body":6,"description":674,"extension":675,"links":676,"meta":677,"navigation":679,"path":680,"seo":681,"stem":682,"__hash__":683},"docs\u002F1.cli\u002F2.reports.md","Reports",{"type":7,"value":8,"toc":664},"minimark",[9,18,100,107,112,115,184,198,202,205,216,267,292,296,311,329,332,368,401,406,443,447,457,471,475,497,533,548,552,555,591,602,613,649,660],[10,11,12,13,17],"p",{},"Without ",[14,15,16],"code",{},"--format",", Doctor picks the report for whoever reads it. Pass a format whenever a script needs a fixed contract:",[19,20,25],"pre",{"className":21,"code":22,"language":23,"meta":24,"style":24},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","pnpm dlx vite-doctor . --format agent\npnpm dlx vite-doctor . --format json\npnpm dlx vite-doctor . --format sarif\npnpm dlx vite-doctor . --format text\n","bash","",[14,26,27,52,68,84],{"__ignoreMap":24},[28,29,32,36,40,43,46,49],"span",{"class":30,"line":31},"line",1,[28,33,35],{"class":34},"sBMFI","pnpm",[28,37,39],{"class":38},"sfazB"," dlx",[28,41,42],{"class":38}," vite-doctor",[28,44,45],{"class":38}," .",[28,47,48],{"class":38}," --format",[28,50,51],{"class":38}," agent\n",[28,53,55,57,59,61,63,65],{"class":30,"line":54},2,[28,56,35],{"class":34},[28,58,39],{"class":38},[28,60,42],{"class":38},[28,62,45],{"class":38},[28,64,48],{"class":38},[28,66,67],{"class":38}," json\n",[28,69,71,73,75,77,79,81],{"class":30,"line":70},3,[28,72,35],{"class":34},[28,74,39],{"class":38},[28,76,42],{"class":38},[28,78,45],{"class":38},[28,80,48],{"class":38},[28,82,83],{"class":38}," sarif\n",[28,85,87,89,91,93,95,97],{"class":30,"line":86},4,[28,88,35],{"class":34},[28,90,39],{"class":38},[28,92,42],{"class":38},[28,94,45],{"class":38},[28,96,48],{"class":38},[28,98,99],{"class":38}," text\n",[10,101,102,103,106],{},"Stdout carries only the report. Anything else that writes to stdout during the run, such as a ",[14,104,105],{},"doctor.config.ts",", a Vite plugin, or a Tailwind plugin that prints a banner, goes to stderr, so you can pipe the report straight into a JSON parser.",[108,109,111],"h2",{"id":110},"who-reads-the-report","Who reads the report",[10,113,114],{},"Doctor picks the first reader that matches:",[116,117,118,134],"table",{},[119,120,121],"thead",{},[122,123,124,128,131],"tr",{},[125,126,127],"th",{},"Reader",[125,129,130],{},"Recognized by",[125,132,133],{},"Report",[135,136,137,152,163,174],"tbody",{},[122,138,139,143,149],{},[140,141,142],"td",{},"Agent",[140,144,145,148],{},[14,146,147],{},"AI_AGENT",", or the marker of an agent that runs commands for a model (Claude Code, Codex, Cursor agent, Gemini CLI, Cline, OpenCode, Augment, Amp), in a terminal or in CI. Markers that can linger in a person's shell, such as Cursor's editor terminal, count only when output goes to a pipe outside CI.",[140,150,151],{},"Agent report, 8,000 characters",[122,153,154,157,160],{},[140,155,156],{},"CI",[140,158,159],{},"A CI environment with no agent marker",[140,161,162],{},"Complete text report",[122,164,165,168,171],{},[140,166,167],{},"Terminal",[140,169,170],{},"Output to a terminal",[140,172,173],{},"Text report, 8,000 characters",[122,175,176,179,182],{},[140,177,178],{},"Pipe",[140,180,181],{},"Anything else",[140,183,173],{},[10,185,186,193,194,197],{},[187,188,192],"a",{"href":189,"rel":190},"https:\u002F\u002Freaderly.loadsheet.dev\u002Fguide\u002Freaders",[191],"nofollow","readerly"," does the detection, and ",[14,195,196],{},"AI_AGENT=0"," turns it off. An agent gets the agent report even in CI or in a terminal it drives. When Doctor picks the agent report and stderr is a terminal, it says so on stderr.",[108,199,201],{"id":200},"report-budget","Report Budget",[10,203,204],{},"Text and agent reports are Progressive Reports. They print the head in full: project, evidence, summary, and every Diagnostic Code with its count. Then they fold Diagnostics into one group per Diagnostic Code, errors before warnings. Each group shows its Rule's title, its shared remediation and evidence, and one row per Diagnostic with its location, or what it is about when it has no file. Doctor adds rows, then each Diagnostic in detail, until the report reaches its Report Budget of 8,000 characters. In CI the text report has no budget by default.",[10,206,207,208,211,212,215],{},"The Report Budget limits optional detail, not required content. If the required content alone exceeds the budget, the report can be longer. When the budget hides something, the report says how much and names the command that shows more. A group's ",[14,209,210],{},"more:"," flags rerun only its Rule, and ",[14,213,214],{},"--full"," prints everything in detail:",[19,217,219],{"className":21,"code":218,"language":23,"meta":24,"style":24},"pnpm dlx vite-doctor . --max-chars 20000\npnpm dlx vite-doctor . --rules mcp\u002Ftools\u002Frequire-annotation-title\npnpm dlx vite-doctor . --full\n",[14,220,221,238,254],{"__ignoreMap":24},[28,222,223,225,227,229,231,234],{"class":30,"line":31},[28,224,35],{"class":34},[28,226,39],{"class":38},[28,228,42],{"class":38},[28,230,45],{"class":38},[28,232,233],{"class":38}," --max-chars",[28,235,237],{"class":236},"sbssI"," 20000\n",[28,239,240,242,244,246,248,251],{"class":30,"line":54},[28,241,35],{"class":34},[28,243,39],{"class":38},[28,245,42],{"class":38},[28,247,45],{"class":38},[28,249,250],{"class":38}," --rules",[28,252,253],{"class":38}," mcp\u002Ftools\u002Frequire-annotation-title\n",[28,255,256,258,260,262,264],{"class":30,"line":70},[28,257,35],{"class":34},[28,259,39],{"class":38},[28,261,42],{"class":38},[28,263,45],{"class":38},[28,265,266],{"class":38}," --full\n",[10,268,269,272,273,275,276,279,280,283,284,287,288,291],{},[14,270,271],{},"--max-chars \u003Ccount>"," sets the budget and ",[14,274,214],{}," removes it; you can't combine them. Both apply to text and agent reports only. JSON and SARIF reports always contain every Diagnostic. The budget changes what a report prints, never the run, so exit codes and ",[14,277,278],{},"--max-warnings"," count every Diagnostic. The Plugin Surface takes the same budget as ",[14,281,282],{},"maxChars",", and its report names ",[14,285,286],{},"rules"," and ",[14,289,290],{},"maxChars: Infinity"," instead of a command.",[108,293,295],{"id":294},"the-agent-report","The agent report",[10,297,298,299,302,303,306,307,310],{},"The agent report (",[14,300,301],{},"vite-doctor.agent\u002Fv3",") groups Diagnostics by Diagnostic Code, severity, and confidence. A code can appear in several ",[14,304,305],{},"groups"," entries, so use ",[14,308,309],{},"codes"," for the complete count per code.",[10,312,313,314,317,318,321,322,324,325,328],{},"A group carries what its Diagnostics share: the Rule, title, severity, confidence, Diagnostic Reference URL, remediation, and evidence. Evidence that only some Diagnostics share says how many with ",[14,315,316],{},"diagnostics",". A group without evidence has no ",[14,319,320],{},"evidence"," field. Each entry in the group's ",[14,323,316],{}," is either a row (relative location or ",[14,326,327],{},"subject",", brief or message, fix safety) or, when the budget leaves room, the whole Diagnostic with its fingerprint, evidence, data, and edit plan.",[10,330,331],{},"Confidence comes from the Rule:",[333,334,335,342,356],"ul",{},[336,337,338,341],"li",{},[14,339,340],{},"proven"," for syntax facts.",[336,343,344,347,348,351,352,355],{},[14,345,346],{},"type-backed",", ",[14,349,350],{},"manifest-backed",", or ",[14,353,354],{},"runtime-backed"," when that evidence decides the finding.",[336,357,358,347,361,351,364,367],{},[14,359,360],{},"heuristic-high",[14,362,363],{},"heuristic-medium",[14,365,366],{},"heuristic-low"," otherwise.",[10,369,370,371,374,375,377,378,381,382,385,386,389,390,393,394,396,397,400],{},"When the budget hides anything, ",[14,372,373],{},"budget"," reports ",[14,376,282],{}," and how many groups, rows, and detailed Diagnostics are ",[14,379,380],{},"hidden",", and each group with hidden rows reports ",[14,383,384],{},"rowsHidden",". Append a group's ",[14,387,388],{},"more"," flags to ",[14,391,392],{},"commandArgs.more"," to see more of it. If a compact group has no ",[14,395,388],{}," flags, such as a baseline finding that needs full Rule coverage, use ",[14,398,399],{},"commandArgs.full"," to keep the original Rule selection.",[402,403,405],"h3",{"id":404},"design-system-findings","Design-system findings",[10,407,408,409,412,413,416,417,347,420,422,423,425,426,429,430,347,432,435,436,439,440,442],{},"When a complete agent report doesn't fit the budget and has both ",[14,410,411],{},"design-system\u002F*"," and other findings, Doctor budgets the other findings first. With space left, it appends design-system count entries grouped by Rule and severity, with ",[14,414,415],{},"count",", the number of ",[14,418,419],{},"files",[14,421,384],{},", and the ",[14,424,388],{}," flags that list that Rule's Diagnostics. Count entries that don't fit go into ",[14,427,428],{},"budget.hidden"," with their rows. Severity doesn't change, and ",[14,431,309],{},[14,433,434],{},"summary",", and exit codes still count every finding. A report that fits, a run with ",[14,437,438],{},"--rules"," or ",[14,441,214],{},", and the JSON, SARIF, and text reports list design-system findings like any other group.",[108,444,446],{"id":445},"score","Score",[10,448,449,450,452,453,456],{},"The JSON report carries ",[14,451,445],{}," and, per Diagnostic category, ",[14,454,455],{},"categoryScores",". Each Diagnostic costs its severity's weight (blocker 15, error 8, warn 3, info 1) and the score is 100 minus the total, never below 0. No severity has a cap, so 10 warnings score 70 and 1,000 warnings score 0. The score never divides by the size of the project: a larger project with the same findings scores the same.",[10,458,459,460,463,464,467,468,470],{},"Set other weights in ",[14,461,462],{},"doctor.config.json",", for example ",[14,465,466],{},"{ \"score\": { \"weights\": { \"warn\": 1 } } }",". Gate CI on ",[14,469,278],{}," and the exit code, which count Diagnostics rather than points.",[108,472,474],{"id":473},"rerun-commands","Rerun commands",[10,476,477,478,481,482,439,485,488,489,492,493,496],{},"For automation, use the ",[14,479,480],{},"commandArgs"," arrays. The first item is the executable and the rest are literal arguments. Replace the ",[14,483,484],{},"\u003Ccode>",[14,486,487],{},"\u003Crule>"," item, then run the array without a shell from ",[14,490,491],{},"project.cwd",". This keeps revision names and preset selectors with spaces or shell syntax intact on every platform. The ",[14,494,495],{},"commands"," strings are quoted templates for POSIX shells, not Windows command lines.",[10,498,499,500,503,504,507,508,347,510,512,513,516,517,519,520,347,523,347,526,347,529,532],{},"The commands keep the run's Rule selection, severity, analyses, baseline filtering, warning limit, cache policy, profiling, and an explicit ",[14,501,502],{},"--config"," path. ",[14,505,506],{},"verify"," replaces the Rule selector with ",[14,509,487],{},[14,511,388],{}," drops it, and ",[14,514,515],{},"full"," adds ",[14,518,214],{},". They omit ",[14,521,522],{},"--fix",[14,524,525],{},"--unsafe-fix",[14,527,528],{},"--watch",[14,530,531],{},"--max-chars",", and baseline updates, so verifying never edits source or baselines. Doctor never discovers executable configuration when it builds these commands.",[10,534,535,536,539,540,543,544,547],{},"API callers can pass ",[14,537,538],{},"{ runOptions, configFile }"," to ",[14,541,542],{},"createAgentReport",", or as the third argument to ",[14,545,546],{},"createReport",", to keep the same CLI options. A command cannot rebuild in-memory host configuration or Doctor Extensions, so repeat those runs through the original Plugin Surface.",[108,549,551],{"id":550},"rules-from-an-extension","Rules from an extension",[10,553,554],{},"Pass the same config when you list or explain Rules from a Doctor Extension:",[19,556,558],{"className":21,"code":557,"language":23,"meta":24,"style":24},"pnpm vite-doctor rules --config doctor.config.ts\npnpm vite-doctor explain CUSTOM0001 --config doctor.config.ts\n",[14,559,560,575],{"__ignoreMap":24},[28,561,562,564,566,569,572],{"class":30,"line":31},[28,563,35],{"class":34},[28,565,42],{"class":38},[28,567,568],{"class":38}," rules",[28,570,571],{"class":38}," --config",[28,573,574],{"class":38}," doctor.config.ts\n",[28,576,577,579,581,584,587,589],{"class":30,"line":54},[28,578,35],{"class":34},[28,580,42],{"class":38},[28,582,583],{"class":38}," explain",[28,585,586],{"class":38}," CUSTOM0001",[28,588,571],{"class":38},[28,590,574],{"class":38},[10,592,593,594,597,598,601],{},"Both commands register the configured Rule Packs, including packs an extension's ",[14,595,596],{},"setup"," adds, without running Rules. Agent explanation commands keep the config path. A custom code links to the docs URL its Rule Pack's ",[14,599,600],{},"defineDoctorDiagnostics"," registry declares, or to the Rule's reference link. Doctor never invents a Diagnostic Reference page for a third-party code.",[10,603,604,605,608,609,612],{},"Nuxt modules can register Doctor Extensions through the Nuxt 4 Bridge. ",[14,606,607],{},"nuxt doctor"," loads them. The standalone CLI loads them only with ",[14,610,611],{},"--host-extensions",", because that runs code the host registered:",[19,614,616],{"className":21,"code":615,"language":23,"meta":24,"style":24},"pnpm vite-doctor . --host-extensions --max-warnings 0\npnpm vite-doctor explain ACME0001 --host-extensions\n",[14,617,618,635],{"__ignoreMap":24},[28,619,620,622,624,626,629,632],{"class":30,"line":31},[28,621,35],{"class":34},[28,623,42],{"class":38},[28,625,45],{"class":38},[28,627,628],{"class":38}," --host-extensions",[28,630,631],{"class":38}," --max-warnings",[28,633,634],{"class":236}," 0\n",[28,636,637,639,641,643,646],{"class":30,"line":54},[28,638,35],{"class":34},[28,640,42],{"class":38},[28,642,583],{"class":38},[28,644,645],{"class":38}," ACME0001",[28,647,648],{"class":38}," --host-extensions\n",[10,650,651,652,654,655,659],{},"Agent commands keep ",[14,653,611],{}," when the original run used it. See ",[187,656,658],{"href":657},"\u002Fextending","Extending Doctor"," to write and ship Rules.",[661,662,663],"style",{},"html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}",{"title":24,"searchDepth":54,"depth":54,"links":665},[666,667,668,671,672,673],{"id":110,"depth":54,"text":111},{"id":200,"depth":54,"text":201},{"id":294,"depth":54,"text":295,"children":669},[670],{"id":404,"depth":70,"text":405},{"id":445,"depth":54,"text":446},{"id":473,"depth":54,"text":474},{"id":550,"depth":54,"text":551},"Pick a report format, read the agent report, and size the Report Budget.","md",null,{"icon":678},"i-lucide-file-text",true,"\u002Fcli\u002Freports",{"title":5,"description":674},"1.cli\u002F2.reports","M6YE-QTOdKtJX9_GLsWmYy_zUzDU22xynsBwXXskWRc",[685,690],{"title":686,"path":687,"stem":688,"description":689,"children":-1},"Run Doctor","\u002Fcli","1.cli\u002F1.index","Run framework diagnostics from one command.",{"title":691,"path":692,"stem":693,"description":694,"children":-1},"Configuration","\u002Fcli\u002Fconfiguration","1.cli\u002F3.configuration","Configure Rules, presets, per-path overrides, files, and suppressions.",[696,715,719,723,727,731,735,747,751,773,777,781],{"title":697,"path":687,"stem":688,"children":698,"icon":714},"CLI",[699,700,701,702,706,710],{"title":686,"path":687,"stem":688},{"title":5,"path":680,"stem":682},{"title":691,"path":692,"stem":693},{"title":703,"path":704,"stem":705},"CI and changed files","\u002Fcli\u002Fci","1.cli\u002F4.ci",{"title":707,"path":708,"stem":709},"Workspaces","\u002Fcli\u002Fworkspaces","1.cli\u002F5.workspaces",{"title":711,"path":712,"stem":713},"Cache and speed","\u002Fcli\u002Fcache","1.cli\u002F6.cache","i-lucide-terminal",{"title":716,"path":717,"stem":718},"Nuxt","\u002Fnuxt","2.nuxt",{"title":720,"path":721,"stem":722},"Vue","\u002Fvue","3.vue",{"title":724,"path":725,"stem":726},"Vite","\u002Fvite","4.vite",{"title":728,"path":729,"stem":730},"Nitro","\u002Fnitro","5.nitro",{"title":732,"path":733,"stem":734},"TypeScript","\u002Ftypescript","6.typescript",{"title":736,"path":737,"stem":738,"children":739,"icon":746},"Design system","\u002Fdesign-system","7.design-system\u002F1.index",[740,742],{"title":741,"path":737,"stem":738},"Overview",{"title":743,"path":744,"stem":745},"Classes and styles","\u002Fdesign-system\u002Fclasses","7.design-system\u002F2.classes","i-lucide-swatch-book",{"title":748,"path":749,"stem":750},"Package","\u002Fpackage","8.package",{"title":658,"path":657,"stem":752,"children":753,"icon":772},"9.extending\u002F1.index",[754,756,760,764,768],{"title":755,"path":657,"stem":752},"Write an extension",{"title":757,"path":758,"stem":759},"Visitors","\u002Fextending\u002Fvisitors","9.extending\u002F2.visitors",{"title":761,"path":762,"stem":763},"Ship with a library","\u002Fextending\u002Fshipping","9.extending\u002F3.shipping",{"title":765,"path":766,"stem":767},"Test a Rule","\u002Fextending\u002Ftesting","9.extending\u002F4.testing",{"title":769,"path":770,"stem":771},"Rule inputs","\u002Fextending\u002Frule-inputs","9.extending\u002F5.rule-inputs","i-lucide-puzzle",{"title":774,"path":775,"stem":776},"H3","\u002Fh3","9.h3",{"title":778,"path":779,"stem":780},"MCP","\u002Fmodel-context-protocol","9.model-context-protocol",{"title":782,"path":783,"stem":784},"Pinia","\u002Fpinia","9.pinia",1796492441549,"1c82e0cf-90da-4346-b049-6ae71736a6b9"]