[{"data":1,"prerenderedAt":1752,"buildId":1753},["ShallowReactive",2],{"-cli-configuration":3,"-cli-configuration-surround":1651,"navigation_docs":1662},{"id":4,"title":5,"body":6,"description":1642,"extension":1643,"links":1644,"meta":1645,"navigation":1051,"path":1647,"seo":1648,"stem":1649,"__hash__":1650},"docs\u002F1.cli\u002F3.configuration.md","Configuration",{"type":7,"value":8,"toc":1632},"minimark",[9,18,33,106,123,127,164,173,300,322,338,342,366,429,465,475,479,493,689,704,714,729,733,754,766,795,828,862,881,885,900,917,920,970,976,981,989,1134,1162,1193,1210,1247,1253,1261,1342,1369,1373,1376,1530,1540,1615,1628],[10,11,12,13,17],"p",{},"Doctor needs no config file. It activates Rule Packs from the project's dependencies, so ",[14,15,16],"code",{},"vite-doctor ."," works on its own. Add config only to change Rules, per-path overrides, suppressions, include or exclude globs, or presets.",[10,19,20,21,24,25,28,29,32],{},"Doctor reads two config sources without running project code: ",[14,22,23],{},"doctor.config.json"," and the ",[14,26,27],{},"doctor"," key of ",[14,30,31],{},"vite.config.*",". Define config in only one of them. When Doctor discovers both, it stops with a config error instead of picking one.",[34,35,40],"pre",{"className":36,"code":37,"filename":23,"language":38,"meta":39,"style":39},"language-json shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","{\n  \"rules\": {\n    \"vite\u002Fdefine\u002Fno-secret-define\": \"error\"\n  }\n}\n","json","",[14,41,42,51,70,94,100],{"__ignoreMap":39},[43,44,47],"span",{"class":45,"line":46},"line",1,[43,48,50],{"class":49},"sMK4o","{\n",[43,52,54,57,61,64,67],{"class":45,"line":53},2,[43,55,56],{"class":49},"  \"",[43,58,60],{"class":59},"spNyl","rules",[43,62,63],{"class":49},"\"",[43,65,66],{"class":49},":",[43,68,69],{"class":49}," {\n",[43,71,73,76,80,82,84,87,91],{"class":45,"line":72},3,[43,74,75],{"class":49},"    \"",[43,77,79],{"class":78},"sBMFI","vite\u002Fdefine\u002Fno-secret-define",[43,81,63],{"class":49},[43,83,66],{"class":49},[43,85,86],{"class":49}," \"",[43,88,90],{"class":89},"sfazB","error",[43,92,93],{"class":49},"\"\n",[43,95,97],{"class":45,"line":96},4,[43,98,99],{"class":49},"  }\n",[43,101,103],{"class":45,"line":102},5,[43,104,105],{"class":49},"}\n",[10,107,108,109,111,112,115,116,119,120,122],{},"An automatically discovered ",[14,110,23],{}," that only repeats the defaults gets an info-level ",[14,113,114],{},"DOC0038"," Diagnostic, because the run is the same without it. Delete the file unless a script or CI job passes it with ",[14,117,118],{},"--config",". Doctor doesn't suggest deleting an explicit ",[14,121,118],{}," file or one that replaces non-default host settings.",[124,125,126],"h2",{"id":60},"Rules",[10,128,129,130,133,134,137,138,137,141,137,144,147,148,151,152,155,156,159,160,163],{},"A Rule entry is ",[14,131,132],{},"\"off\"",", a severity (",[14,135,136],{},"\"blocker\"",", ",[14,139,140],{},"\"error\"",[14,142,143],{},"\"warn\"",[14,145,146],{},"\"info\"","), or a ",[14,149,150],{},"[severity, options]"," tuple. A severity also turns on a Rule that no selected preset includes, so ",[14,153,154],{},"\"vue\u002Fprops\u002Fno-unused-props\": \"warn\""," runs that strict-only Rule without the rest of ",[14,157,158],{},"vue\u002Fstrict",". With ",[14,161,162],{},"\"extends\": []",", a config runs exactly the Rules it names.",[10,165,166,167,169,170,172],{},"The Diagnostics Doctor reports about its own inputs take ",[14,168,132],{}," or a severity, in ",[14,171,60],{}," and in overrides, and no options:",[174,175,176,189],"table",{},[177,178,179],"thead",{},[180,181,182,186],"tr",{},[183,184,185],"th",{},"Rule ID",[183,187,188],{},"Code",[190,191,192,205,217,229,241,253,265,276,288],"tbody",{},[180,193,194,200],{},[195,196,197],"td",{},[14,198,199],{},"doctor\u002Finventory\u002Funresolved-runtime",[195,201,202],{},[14,203,204],{},"DOC0022",[180,206,207,212],{},[195,208,209],{},[14,210,211],{},"doctor\u002Fconfig\u002Funused-suppression",[195,213,214],{},[14,215,216],{},"DOC0031",[180,218,219,224],{},[195,220,221],{},[14,222,223],{},"doctor\u002Fbaseline\u002Fstale-fingerprint-scheme",[195,225,226],{},[14,227,228],{},"DOC0032",[180,230,231,236],{},[195,232,233],{},[14,234,235],{},"doctor\u002Finventory\u002Fempty-sfc",[195,237,238],{},[14,239,240],{},"DOC0033",[180,242,243,248],{},[195,244,245],{},[14,246,247],{},"doctor\u002Finline\u002Funused-suppression",[195,249,250],{},[14,251,252],{},"DOC0036",[180,254,255,260],{},[195,256,257],{},[14,258,259],{},"doctor\u002Finline\u002Funknown-suppression-rule",[195,261,262],{},[14,263,264],{},"DOC0037",[180,266,267,272],{},[195,268,269],{},[14,270,271],{},"doctor\u002Fconfig\u002Fdefault-config-file",[195,273,274],{},[14,275,114],{},[180,277,278,283],{},[195,279,280],{},[14,281,282],{},"doctor\u002Fbaseline\u002Fresolved-entries",[195,284,285],{},[14,286,287],{},"DOC0039",[180,289,290,295],{},[195,291,292],{},[14,293,294],{},"doctor\u002Fruntime\u002Fframework-diagnostic",[195,296,297],{},[14,298,299],{},"DOC0040",[10,301,302,303,306,307,309,310,313,314,317,318,321],{},"So ",[14,304,305],{},"\"doctor\u002Finline\u002Funused-suppression\": \"error\""," fails the run on a stale directive, and ",[14,308,132],{}," keeps ",[14,311,312],{},"--fix"," from removing its unused Rule IDs. Any other ",[14,315,316],{},"doctor\u002F"," Rule ID stops the run with ",[14,319,320],{},"DOC0020",".",[10,323,324,325,327,328,330,331,333,334,337],{},"Configure ",[14,326,114],{}," through an inherited source such as a Nuxt manifest: a setting in ",[14,329,23],{}," makes that file non-default, so the Diagnostic no longer applies. ",[14,332,287],{}," still needs a full run that includes ",[14,335,336],{},"info"," findings, even if you raise its severity, because otherwise Doctor cannot tell a resolved baseline entry from a filtered one.",[124,339,341],{"id":340},"files","Files",[10,343,344,345,137,348,137,351,137,354,357,358,361,362,365],{},"By default Doctor analyzes ",[14,346,347],{},".vue",[14,349,350],{},".ts",[14,352,353],{},".tsx",[14,355,356],{},".js",", and ",[14,359,360],{},".jsx"," files and their module variants, plus ",[14,363,364],{},"content\u002F"," Markdown when the project uses Nuxt Content.",[10,367,368,369,137,372,137,375,137,378,137,381,137,384,137,387,137,390,137,393,357,396,399,400,403,404,137,407,410,411,137,414,137,417,420,421,424,425,428],{},"It skips ",[14,370,371],{},"node_modules",[14,373,374],{},"dist",[14,376,377],{},".nuxt",[14,379,380],{},".next",[14,382,383],{},".output",[14,385,386],{},"coverage",[14,388,389],{},"test-results",[14,391,392],{},"playwright-report",[14,394,395],{},"public",[14,397,398],{},"generated"," folders, ",[14,401,402],{},"*.generated.*"," and minified files, ",[14,405,406],{},"fixtures",[14,408,409],{},"__snapshots__",", type-test folders (",[14,412,413],{},"test-d",[14,415,416],{},"dts-test",[14,418,419],{},"type-tests"," and similar), ",[14,422,423],{},"doctor.config.*",", files ",[14,426,427],{},".gitignore"," excludes, and files whose header says they are generated.",[10,430,431,432,137,435,137,438,357,441,444,445,448,449,452,453,460,461,464],{},"Test code is skipped too: files in ",[14,433,434],{},"test",[14,436,437],{},"tests",[14,439,440],{},"__tests__",[14,442,443],{},"test-utils"," folders, and ",[14,446,447],{},"*.test.*"," and ",[14,450,451],{},"*.spec.*"," files. Only a Rule that declares ",[454,455,457],"a",{"href":456},"\u002Fextending\u002Ftesting#test-files",[14,458,459],{},"meta.includeTestFiles"," checks test code. ",[14,462,463],{},"scope.files"," in the report counts test files only when such a Rule checked them.",[10,466,467,470,471,474],{},[14,468,469],{},"include"," replaces the default file globs. ",[14,472,473],{},"exclude"," adds to the skipped paths, so an excluded path is never analyzed, test code included.",[124,476,478],{"id":477},"overrides","Overrides",[10,480,481,483,484,486,487,448,489,492],{},[14,482,477],{}," configures Rules for some paths only, such as library code against playgrounds and docs. Each override has ",[14,485,340],{},", a list of globs relative to the project root, and optional ",[14,488,60],{},[14,490,491],{},"extends",". Overrides apply in order after the top-level config, so a later match wins:",[34,494,496],{"className":36,"code":495,"filename":23,"language":38,"meta":39,"style":39},"{\n  \"extends\": [\"vite-doctor\u002Ftypescript\u002Frecommended\"],\n  \"overrides\": [\n    {\n      \"files\": [\"packages\u002F*\u002Fsrc\u002F**\"],\n      \"rules\": { \"typescript\u002Fboundaries\u002Fno-cross-realm-web-instanceof\": \"error\" }\n    },\n    {\n      \"files\": [\"playground\u002F**\", \"docs\u002F**\"],\n      \"rules\": { \"typescript\u002Fevidence\u002Fno-chained-type-assertions\": \"off\" }\n    }\n  ]\n}\n",[14,497,498,502,525,538,543,565,598,604,609,641,672,678,684],{"__ignoreMap":39},[43,499,500],{"class":45,"line":46},[43,501,50],{"class":49},[43,503,504,506,508,510,512,515,517,520,522],{"class":45,"line":53},[43,505,56],{"class":49},[43,507,491],{"class":59},[43,509,63],{"class":49},[43,511,66],{"class":49},[43,513,514],{"class":49}," [",[43,516,63],{"class":49},[43,518,519],{"class":89},"vite-doctor\u002Ftypescript\u002Frecommended",[43,521,63],{"class":49},[43,523,524],{"class":49},"],\n",[43,526,527,529,531,533,535],{"class":45,"line":72},[43,528,56],{"class":49},[43,530,477],{"class":59},[43,532,63],{"class":49},[43,534,66],{"class":49},[43,536,537],{"class":49}," [\n",[43,539,540],{"class":45,"line":96},[43,541,542],{"class":49},"    {\n",[43,544,545,548,550,552,554,556,558,561,563],{"class":45,"line":102},[43,546,547],{"class":49},"      \"",[43,549,340],{"class":78},[43,551,63],{"class":49},[43,553,66],{"class":49},[43,555,514],{"class":49},[43,557,63],{"class":49},[43,559,560],{"class":89},"packages\u002F*\u002Fsrc\u002F**",[43,562,63],{"class":49},[43,564,524],{"class":49},[43,566,568,570,572,574,576,579,581,585,587,589,591,593,595],{"class":45,"line":567},6,[43,569,547],{"class":49},[43,571,60],{"class":78},[43,573,63],{"class":49},[43,575,66],{"class":49},[43,577,578],{"class":49}," {",[43,580,86],{"class":49},[43,582,584],{"class":583},"sbssI","typescript\u002Fboundaries\u002Fno-cross-realm-web-instanceof",[43,586,63],{"class":49},[43,588,66],{"class":49},[43,590,86],{"class":49},[43,592,90],{"class":89},[43,594,63],{"class":49},[43,596,597],{"class":49}," }\n",[43,599,601],{"class":45,"line":600},7,[43,602,603],{"class":49},"    },\n",[43,605,607],{"class":45,"line":606},8,[43,608,542],{"class":49},[43,610,612,614,616,618,620,622,624,627,629,632,634,637,639],{"class":45,"line":611},9,[43,613,547],{"class":49},[43,615,340],{"class":78},[43,617,63],{"class":49},[43,619,66],{"class":49},[43,621,514],{"class":49},[43,623,63],{"class":49},[43,625,626],{"class":89},"playground\u002F**",[43,628,63],{"class":49},[43,630,631],{"class":49},",",[43,633,86],{"class":49},[43,635,636],{"class":89},"docs\u002F**",[43,638,63],{"class":49},[43,640,524],{"class":49},[43,642,644,646,648,650,652,654,656,659,661,663,665,668,670],{"class":45,"line":643},10,[43,645,547],{"class":49},[43,647,60],{"class":78},[43,649,63],{"class":49},[43,651,66],{"class":49},[43,653,578],{"class":49},[43,655,86],{"class":49},[43,657,658],{"class":583},"typescript\u002Fevidence\u002Fno-chained-type-assertions",[43,660,63],{"class":49},[43,662,66],{"class":49},[43,664,86],{"class":49},[43,666,667],{"class":89},"off",[43,669,63],{"class":49},[43,671,597],{"class":49},[43,673,675],{"class":45,"line":674},11,[43,676,677],{"class":49},"    }\n",[43,679,681],{"class":45,"line":680},12,[43,682,683],{"class":49},"  ]\n",[43,685,687],{"class":45,"line":686},13,[43,688,105],{"class":49},[10,690,691,692,694,695,697,698,700,701,703],{},"In an override, ",[14,693,491],{}," enables a preset's Rules, including Rules turned off earlier. The same override's ",[14,696,60],{}," win over its ",[14,699,491],{},": ",[14,702,132],{}," turns a Rule off, and a severity turns it on or changes it. Earlier Rule options stay unless a new tuple supplies options.",[10,705,706,707,710,711,713],{},"When ",[14,708,709],{},"\"auto\""," activates a Rule Pack for only some workspace packages, overrides cannot widen that scope. A top-level ",[14,712,60],{}," entry that enables a Rule no selected preset includes, an explicit top-level preset, and Rules with workspace-wide activation are not limited this way.",[10,715,716,717,719,720,723,724,726,727,321],{},"Overrides apply to the file a Diagnostic is located in, including Diagnostics from manifest and workspace Rules. Rule options in override tuples apply only to file Rules. Set options for other Rules in top-level ",[14,718,60],{},"; an override tuple with options for them fails with ",[14,721,722],{},"DOC0035",", as does a malformed override. Use ",[14,725,473],{}," when a path should not be analyzed at all. The Vite plugin and the Nuxt module take the same ",[14,728,477],{},[124,730,732],{"id":731},"presets","Presets",[10,734,735,736,738,739,742,743,746,747,750,751,753],{},"By default ",[14,737,491],{}," is ",[14,740,741],{},"auto",": the recommended preset of every Rule Pack the project activates. ",[14,744,745],{},"strict"," selects each activated Rule Pack's strict preset instead, and keeps the recommended preset of packs without one. Strict presets add noisier, opinionated, and migration-oriented Rules, but not opt-in policy Rules such as ",[14,748,749],{},"typescript\u002Fstrict\u002Fno-comments",", which only a ",[14,752,60],{}," entry turns on.",[10,755,756,759,760,763,764,66],{},[14,757,758],{},"--strict"," is short for ",[14,761,762],{},"--extends strict",". In ",[14,765,23],{},[34,767,769],{"className":36,"code":768,"filename":23,"language":38,"meta":39,"style":39},"{\n  \"extends\": \"strict\"\n}\n",[14,770,771,775,791],{"__ignoreMap":39},[43,772,773],{"class":45,"line":46},[43,774,50],{"class":49},[43,776,777,779,781,783,785,787,789],{"class":45,"line":53},[43,778,56],{"class":49},[43,780,491],{"class":59},[43,782,63],{"class":49},[43,784,66],{"class":49},[43,786,86],{"class":49},[43,788,745],{"class":89},[43,790,93],{"class":49},[43,792,793],{"class":45,"line":72},[43,794,105],{"class":49},[10,796,797,798,800,801,804,805,807,808,810,811,814,815,817,818,821,822,824,825,827],{},"An explicit ",[14,799,491],{}," list selects exactly the presets it names and replaces the activated defaults. ",[14,802,803],{},"--extends vite-doctor\u002Ftypescript\u002Fstrict"," runs only the TypeScript strict preset, without the Vite, Vue, Nitro, or Nuxt presets the project activated. Add ",[14,806,741],{}," or ",[14,809,745],{}," to keep them: ",[14,812,813],{},"--extends auto,vite-doctor\u002Ftypescript\u002Fstrict",". ",[14,816,758],{}," with ",[14,819,820],{},"--extends"," adds ",[14,823,745],{}," to the list. The CLI, the Vite plugin, and the Nuxt module treat ",[14,826,491],{}," the same way.",[10,829,830,831,834,835,814,838,841,842,844,845,848,849,851,852,137,855,858,859,861],{},"The JSON and agent reports list each Rule Pack once under ",[14,832,833],{},"rulePacks",", as ",[14,836,837],{},"{ name, selected, activatedBy }",[14,839,840],{},"selected"," says whether ",[14,843,491],{}," selected its presets, and ",[14,846,847],{},"activatedBy"," lists the roots of the workspace packages that activate it (",[14,850,321],{}," is the root). Selected doesn't mean every Rule ran: ",[14,853,854],{},"--rules",[14,856,857],{},"--analyses",", and Rule options can narrow the run. The text report names activated Rule Packs that ",[14,860,491],{}," left out.",[10,863,864,865,868,869,872,873,876,877,880],{},"Selectors use ",[14,866,867],{},"pack\u002Fpreset",", with the Rule Pack's full name, such as ",[14,870,871],{},"vendor\u002Fvite\u002Frecommended",", or its short name when that is unique. When several installed packs share a short name, Doctor reports an ambiguity (",[14,874,875],{},"DOC0024",") instead of choosing by registration order; use the full name. Duplicate full names fail at registration with ",[14,878,879],{},"DOC0023",". An exact full name wins over another pack's short alias.",[124,882,884],{"id":883},"suppressions","Suppressions",[10,886,887,888,891,892,895,896,899],{},"Inline ",[14,889,890],{},"doctor-disable"," directives apply only to Diagnostics with a source range. ",[14,893,894],{},"doctor-disable-next-line \u003Crule> -- \u003Creason>"," applies to the next line that contains code, so comments such as ",[14,897,898],{},"\u002F\u002F SAFETY:"," notes and blank lines can sit in between.",[10,901,902,903,905,906,909,910,913,914,321],{},"To suppress a Diagnostic without a source range, add a ",[14,904,883],{}," entry with its ",[14,907,908],{},"ruleId",", an optional ",[14,911,912],{},"file",", and a ",[14,915,916],{},"reason",[10,918,919],{},"Doctor reports suppressions that no longer match:",[921,922,923,955,965],"ul",{},[924,925,926,928,929,931,932,137,935,137,938,940,941,943,944,946,947,949,950,807,952,954],"li",{},[14,927,216],{},": a ",[14,930,883],{}," entry that a full run of its Rule matched nothing. Runs with ",[14,933,934],{},"--changed",[14,936,937],{},"--since",[14,939,854],{},", or ",[14,942,857],{}," never report it. An entry whose ",[14,945,912],{}," was excluded or failed to parse is reported only when that path no longer exists, and an entry without a ",[14,948,908],{}," only when the run uses ",[14,951,741],{},[14,953,745],{}," and turns no Rule off.",[924,956,957,959,960,448,962,964],{},[14,958,252],{},": an inline directive whose file Rule ran on that file and reported nothing it covers. Rules without confirmed file coverage, such as workspace and manifest Rules, never make a directive stale. ",[14,961,934],{},[14,963,937],{}," runs report only directives inside the change.",[924,966,967,969],{},[14,968,264],{},": a directive that names an unknown Rule ID in a loaded Rule Pack's namespace, or a Diagnostic Code instead of a Rule ID.",[10,971,972,975],{},[14,973,974],{},"vite-doctor . --fix"," removes either kind of stale ID when the edit is safe. When removal could change how another directive applies, Doctor offers a suggestion instead.",[124,977,979],{"id":978},"viteconfig",[14,980,31],{},[10,982,983,984,28,986,988],{},"The ",[14,985,27],{},[14,987,31],{}," keeps Doctor config next to the rest of a Vite or Vite+ toolchain:",[34,990,995],{"className":991,"code":992,"filename":993,"language":994,"meta":39,"style":39},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { defineConfig } from \"vite-plus\";\nimport { defineDoctorConfig } from \"vite-doctor\";\n\nexport default defineConfig({\n  doctor: defineDoctorConfig({\n    rules: {\n      \"vite\u002Fdefine\u002Fno-secret-define\": \"error\",\n    },\n  }),\n});\n","vite.config.ts","ts",[14,996,997,1025,1047,1053,1069,1083,1092,1111,1115,1125],{"__ignoreMap":39},[43,998,999,1003,1005,1009,1012,1015,1017,1020,1022],{"class":45,"line":46},[43,1000,1002],{"class":1001},"s7zQu","import",[43,1004,578],{"class":49},[43,1006,1008],{"class":1007},"sTEyZ"," defineConfig",[43,1010,1011],{"class":49}," }",[43,1013,1014],{"class":1001}," from",[43,1016,86],{"class":49},[43,1018,1019],{"class":89},"vite-plus",[43,1021,63],{"class":49},[43,1023,1024],{"class":49},";\n",[43,1026,1027,1029,1031,1034,1036,1038,1040,1043,1045],{"class":45,"line":53},[43,1028,1002],{"class":1001},[43,1030,578],{"class":49},[43,1032,1033],{"class":1007}," defineDoctorConfig",[43,1035,1011],{"class":49},[43,1037,1014],{"class":1001},[43,1039,86],{"class":49},[43,1041,1042],{"class":89},"vite-doctor",[43,1044,63],{"class":49},[43,1046,1024],{"class":49},[43,1048,1049],{"class":45,"line":72},[43,1050,1052],{"emptyLinePlaceholder":1051},true,"\n",[43,1054,1055,1058,1061,1064,1067],{"class":45,"line":96},[43,1056,1057],{"class":1001},"export",[43,1059,1060],{"class":1001}," default",[43,1062,1008],{"class":1063},"s2Zo4",[43,1065,1066],{"class":1007},"(",[43,1068,50],{"class":49},[43,1070,1071,1075,1077,1079,1081],{"class":45,"line":102},[43,1072,1074],{"class":1073},"swJcz","  doctor",[43,1076,66],{"class":49},[43,1078,1033],{"class":1063},[43,1080,1066],{"class":1007},[43,1082,50],{"class":49},[43,1084,1085,1088,1090],{"class":45,"line":567},[43,1086,1087],{"class":1073},"    rules",[43,1089,66],{"class":49},[43,1091,69],{"class":49},[43,1093,1094,1096,1098,1100,1102,1104,1106,1108],{"class":45,"line":600},[43,1095,547],{"class":49},[43,1097,79],{"class":1073},[43,1099,63],{"class":49},[43,1101,66],{"class":49},[43,1103,86],{"class":49},[43,1105,90],{"class":89},[43,1107,63],{"class":49},[43,1109,1110],{"class":49},",\n",[43,1112,1113],{"class":45,"line":606},[43,1114,603],{"class":49},[43,1116,1117,1120,1123],{"class":45,"line":611},[43,1118,1119],{"class":49},"  }",[43,1121,1122],{"class":1007},")",[43,1124,1110],{"class":49},[43,1126,1127,1130,1132],{"class":45,"line":643},[43,1128,1129],{"class":49},"}",[43,1131,1122],{"class":1007},[43,1133,1024],{"class":49},[10,1135,1136,1137,1139,1140,1142,1143,1145,1146,1149,1150,1153,1154,1158,1159,321],{},"Doctor parses ",[14,1138,31],{}," in the checked directory instead of running it, and doesn't follow imports, so it ignores a ",[14,1141,27],{}," key that only an imported base config supplies. A discovered ",[14,1144,23],{}," still applies, and the CLI uses defaults only when no Doctor config applies. The ",[14,1147,1148],{},"doctor()"," Vite plugin reads the same key when its own ",[14,1151,1152],{},"config"," option is not set. See ",[454,1155,1157],{"href":1156},"\u002Fvite#run-doctor-with-vite","Run Doctor with Vite+"," for running Doctor through ",[14,1160,1161],{},"vp",[10,1163,1164,1165,1168,1169,137,1172,940,1174,1177,1178,1181,1182,1185,1186,1188,1189,1192],{},"Doctor accepts an exported object, or a function that directly returns one, optionally wrapped in ",[14,1166,1167],{},"defineConfig()"," from ",[14,1170,1171],{},"vite",[14,1173,1019],{},[14,1175,1176],{},"vitest\u002Fconfig",". A block-bodied function must end in a direct return, with only variable declarations or expression statements before it. Export it with ",[14,1179,1180],{},"export default",", a top-level ",[14,1183,1184],{},"const"," used only as the default export or as the ",[14,1187,1167],{}," argument, or one top-level ",[14,1190,1191],{},"module.exports"," assignment.",[10,1194,983,1195,1197,1198,1201,1202,1168,1205,807,1207,321],{},[14,1196,27],{}," value must be a literal: strings, numbers, booleans, ",[14,1199,1200],{},"null",", arrays, and objects, optionally wrapped in ",[14,1203,1204],{},"defineDoctorConfig()",[14,1206,1042],{},[14,1208,1209],{},"vite-doctor\u002Fconfig",[10,1211,1212,1213,1215,1216,1218,1219,1222,1223,940,1226,1228,1229,1232,1233,1235,1236,1239,1240,1243,1244,1246],{},"When Doctor cannot tell whether the file exports a ",[14,1214,27],{}," key or what its value is, it reports a config error with the line number. A non-static export with a ",[14,1217,27],{}," key at any depth, a ",[14,1220,1221],{},".doctor"," read or write, a destructured ",[14,1224,1225],{},"{ doctor }",[14,1227,1204],{}," is an error. Without those references, exports that use ",[14,1230,1231],{},"mergeConfig()",", spreads, conditional returns, or the ",[14,1234,1148],{}," plugin generally don't block a CLI run. Doctor checks unresolved computed keys only when it resolves the export to one config object, and doesn't follow conditional returns to find them. For a dynamic config, pass ",[14,1237,1238],{},"--config doctor.config.json"," (use ",[14,1241,1242],{},"{}"," for defaults) or use the ",[14,1245,1148],{}," Vite plugin.",[124,1248,1250],{"id":1249},"doctorconfigts",[14,1251,1252],{},"doctor.config.ts",[10,1254,1255,1256,1258,1259,66],{},"Use ",[14,1257,1252],{}," only when configuration needs code. Loading it runs project code, so the CLI loads it only with ",[14,1260,118],{},[34,1262,1264],{"className":991,"code":1263,"filename":1252,"language":994,"meta":39,"style":39},"import { defineDoctorConfig } from \"vite-doctor\u002Fconfig\";\n\nexport default defineDoctorConfig({\n  rules: {\n    \"vite\u002Fdefine\u002Fno-secret-define\": \"error\",\n  },\n});\n",[14,1265,1266,1286,1290,1302,1311,1329,1334],{"__ignoreMap":39},[43,1267,1268,1270,1272,1274,1276,1278,1280,1282,1284],{"class":45,"line":46},[43,1269,1002],{"class":1001},[43,1271,578],{"class":49},[43,1273,1033],{"class":1007},[43,1275,1011],{"class":49},[43,1277,1014],{"class":1001},[43,1279,86],{"class":49},[43,1281,1209],{"class":89},[43,1283,63],{"class":49},[43,1285,1024],{"class":49},[43,1287,1288],{"class":45,"line":53},[43,1289,1052],{"emptyLinePlaceholder":1051},[43,1291,1292,1294,1296,1298,1300],{"class":45,"line":72},[43,1293,1057],{"class":1001},[43,1295,1060],{"class":1001},[43,1297,1033],{"class":1063},[43,1299,1066],{"class":1007},[43,1301,50],{"class":49},[43,1303,1304,1307,1309],{"class":45,"line":96},[43,1305,1306],{"class":1073},"  rules",[43,1308,66],{"class":49},[43,1310,69],{"class":49},[43,1312,1313,1315,1317,1319,1321,1323,1325,1327],{"class":45,"line":102},[43,1314,75],{"class":49},[43,1316,79],{"class":1073},[43,1318,63],{"class":49},[43,1320,66],{"class":49},[43,1322,86],{"class":49},[43,1324,90],{"class":89},[43,1326,63],{"class":49},[43,1328,1110],{"class":49},[43,1330,1331],{"class":45,"line":567},[43,1332,1333],{"class":49},"  },\n",[43,1335,1336,1338,1340],{"class":45,"line":600},[43,1337,1129],{"class":49},[43,1339,1122],{"class":1007},[43,1341,1024],{"class":49},[34,1343,1347],{"className":1344,"code":1345,"language":1346,"meta":39,"style":39},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","pnpm dlx vite-doctor . --config doctor.config.ts\n","bash",[14,1348,1349],{"__ignoreMap":39},[43,1350,1351,1354,1357,1360,1363,1366],{"class":45,"line":46},[43,1352,1353],{"class":78},"pnpm",[43,1355,1356],{"class":89}," dlx",[43,1358,1359],{"class":89}," vite-doctor",[43,1361,1362],{"class":89}," .",[43,1364,1365],{"class":89}," --config",[43,1367,1368],{"class":89}," doctor.config.ts\n",[124,1370,1372],{"id":1371},"plugin-surfaces","Plugin Surfaces",[10,1374,1375],{},"When Doctor runs through a host integration, pass the same config to the plugin:",[34,1377,1379],{"className":991,"code":1378,"filename":993,"language":994,"meta":39,"style":39},"import { doctor } from \"vite-doctor\";\n\nexport default {\n  plugins: [\n    doctor({\n      config: {\n        include: [\"src\u002F**\", \"vite.config.ts\"],\n        rules: {\n          \"vite\u002Fdefine\u002Fno-secret-define\": \"error\",\n        },\n      },\n    }),\n  ],\n};\n",[14,1380,1381,1402,1406,1414,1423,1432,1441,1470,1479,1498,1503,1508,1517,1524],{"__ignoreMap":39},[43,1382,1383,1385,1387,1390,1392,1394,1396,1398,1400],{"class":45,"line":46},[43,1384,1002],{"class":1001},[43,1386,578],{"class":49},[43,1388,1389],{"class":1007}," doctor",[43,1391,1011],{"class":49},[43,1393,1014],{"class":1001},[43,1395,86],{"class":49},[43,1397,1042],{"class":89},[43,1399,63],{"class":49},[43,1401,1024],{"class":49},[43,1403,1404],{"class":45,"line":53},[43,1405,1052],{"emptyLinePlaceholder":1051},[43,1407,1408,1410,1412],{"class":45,"line":72},[43,1409,1057],{"class":1001},[43,1411,1060],{"class":1001},[43,1413,69],{"class":49},[43,1415,1416,1419,1421],{"class":45,"line":96},[43,1417,1418],{"class":1073},"  plugins",[43,1420,66],{"class":49},[43,1422,537],{"class":1007},[43,1424,1425,1428,1430],{"class":45,"line":102},[43,1426,1427],{"class":1063},"    doctor",[43,1429,1066],{"class":1007},[43,1431,50],{"class":49},[43,1433,1434,1437,1439],{"class":45,"line":567},[43,1435,1436],{"class":1073},"      config",[43,1438,66],{"class":49},[43,1440,69],{"class":49},[43,1442,1443,1446,1448,1450,1452,1455,1457,1459,1461,1463,1465,1468],{"class":45,"line":600},[43,1444,1445],{"class":1073},"        include",[43,1447,66],{"class":49},[43,1449,514],{"class":1007},[43,1451,63],{"class":49},[43,1453,1454],{"class":89},"src\u002F**",[43,1456,63],{"class":49},[43,1458,631],{"class":49},[43,1460,86],{"class":49},[43,1462,993],{"class":89},[43,1464,63],{"class":49},[43,1466,1467],{"class":1007},"]",[43,1469,1110],{"class":49},[43,1471,1472,1475,1477],{"class":45,"line":606},[43,1473,1474],{"class":1073},"        rules",[43,1476,66],{"class":49},[43,1478,69],{"class":49},[43,1480,1481,1484,1486,1488,1490,1492,1494,1496],{"class":45,"line":611},[43,1482,1483],{"class":49},"          \"",[43,1485,79],{"class":1073},[43,1487,63],{"class":49},[43,1489,66],{"class":49},[43,1491,86],{"class":49},[43,1493,90],{"class":89},[43,1495,63],{"class":49},[43,1497,1110],{"class":49},[43,1499,1500],{"class":45,"line":643},[43,1501,1502],{"class":49},"        },\n",[43,1504,1505],{"class":45,"line":674},[43,1506,1507],{"class":49},"      },\n",[43,1509,1510,1513,1515],{"class":45,"line":680},[43,1511,1512],{"class":49},"    }",[43,1514,1122],{"class":1007},[43,1516,1110],{"class":49},[43,1518,1519,1522],{"class":45,"line":686},[43,1520,1521],{"class":1007},"  ]",[43,1523,1110],{"class":49},[43,1525,1527],{"class":45,"line":1526},14,[43,1528,1529],{"class":49},"};\n",[10,1531,1532,1533,1535,1536,1539],{},"The same ",[14,1534,1148],{}," plugin covers Vite, Vue, and Nitro projects and picks the matching Diagnostics. Set ",[14,1537,1538],{},"framework: \"nitro\""," only when Doctor cannot identify the framework:",[34,1541,1543],{"className":991,"code":1542,"filename":993,"language":994,"meta":39,"style":39},"import { doctor } from \"vite-doctor\";\n\nexport default {\n  plugins: [doctor({ framework: \"nitro\" })],\n};\n",[14,1544,1545,1565,1569,1577,1611],{"__ignoreMap":39},[43,1546,1547,1549,1551,1553,1555,1557,1559,1561,1563],{"class":45,"line":46},[43,1548,1002],{"class":1001},[43,1550,578],{"class":49},[43,1552,1389],{"class":1007},[43,1554,1011],{"class":49},[43,1556,1014],{"class":1001},[43,1558,86],{"class":49},[43,1560,1042],{"class":89},[43,1562,63],{"class":49},[43,1564,1024],{"class":49},[43,1566,1567],{"class":45,"line":53},[43,1568,1052],{"emptyLinePlaceholder":1051},[43,1570,1571,1573,1575],{"class":45,"line":72},[43,1572,1057],{"class":1001},[43,1574,1060],{"class":1001},[43,1576,69],{"class":49},[43,1578,1579,1581,1583,1585,1587,1589,1592,1595,1597,1599,1602,1604,1606,1609],{"class":45,"line":96},[43,1580,1418],{"class":1073},[43,1582,66],{"class":49},[43,1584,514],{"class":1007},[43,1586,27],{"class":1063},[43,1588,1066],{"class":1007},[43,1590,1591],{"class":49},"{",[43,1593,1594],{"class":1073}," framework",[43,1596,66],{"class":49},[43,1598,86],{"class":49},[43,1600,1601],{"class":89},"nitro",[43,1603,63],{"class":49},[43,1605,1011],{"class":49},[43,1607,1608],{"class":1007},")]",[43,1610,1110],{"class":49},[43,1612,1613],{"class":45,"line":102},[43,1614,1529],{"class":49},[10,1616,1617,1618,28,1620,1623,1624,321],{},"Nuxt projects put the same config under the ",[14,1619,27],{},[14,1621,1622],{},"nuxt.config.ts",". See ",[454,1625,1627],{"href":1626},"\u002Fnuxt","Nuxt",[1629,1630,1631],"style",{},"html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}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}html pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}",{"title":39,"searchDepth":53,"depth":53,"links":1633},[1634,1635,1636,1637,1638,1639,1640,1641],{"id":60,"depth":53,"text":126},{"id":340,"depth":53,"text":341},{"id":477,"depth":53,"text":478},{"id":731,"depth":53,"text":732},{"id":883,"depth":53,"text":884},{"id":978,"depth":53,"text":31},{"id":1249,"depth":53,"text":1252},{"id":1371,"depth":53,"text":1372},"Configure Rules, presets, per-path overrides, files, and suppressions.","md",null,{"icon":1646},"i-lucide-settings","\u002Fcli\u002Fconfiguration",{"title":5,"description":1642},"1.cli\u002F3.configuration","3hDRFmCFJG7bXY4UZc1Jh0LUb9j07yRE6bK64Qu9Db4",[1652,1657],{"title":1653,"path":1654,"stem":1655,"description":1656,"children":-1},"Reports","\u002Fcli\u002Freports","1.cli\u002F2.reports","Pick a report format, read the agent report, and size the Report Budget.",{"title":1658,"path":1659,"stem":1660,"description":1661,"children":-1},"CI and changed files","\u002Fcli\u002Fci","1.cli\u002F4.ci","Run Doctor in CI, report only changed lines, and record existing findings in a baseline.",[1663,1682,1684,1688,1692,1696,1700,1712,1716,1740,1744,1748],{"title":1664,"path":1665,"stem":1666,"children":1667,"icon":1681},"CLI","\u002Fcli","1.cli\u002F1.index",[1668,1670,1671,1672,1673,1677],{"title":1669,"path":1665,"stem":1666},"Run Doctor",{"title":1653,"path":1654,"stem":1655},{"title":5,"path":1647,"stem":1649},{"title":1658,"path":1659,"stem":1660},{"title":1674,"path":1675,"stem":1676},"Workspaces","\u002Fcli\u002Fworkspaces","1.cli\u002F5.workspaces",{"title":1678,"path":1679,"stem":1680},"Cache and speed","\u002Fcli\u002Fcache","1.cli\u002F6.cache","i-lucide-terminal",{"title":1627,"path":1626,"stem":1683},"2.nuxt",{"title":1685,"path":1686,"stem":1687},"Vue","\u002Fvue","3.vue",{"title":1689,"path":1690,"stem":1691},"Vite","\u002Fvite","4.vite",{"title":1693,"path":1694,"stem":1695},"Nitro","\u002Fnitro","5.nitro",{"title":1697,"path":1698,"stem":1699},"TypeScript","\u002Ftypescript","6.typescript",{"title":1701,"path":1702,"stem":1703,"children":1704,"icon":1711},"Design system","\u002Fdesign-system","7.design-system\u002F1.index",[1705,1707],{"title":1706,"path":1702,"stem":1703},"Overview",{"title":1708,"path":1709,"stem":1710},"Classes and styles","\u002Fdesign-system\u002Fclasses","7.design-system\u002F2.classes","i-lucide-swatch-book",{"title":1713,"path":1714,"stem":1715},"Package","\u002Fpackage","8.package",{"title":1717,"path":1718,"stem":1719,"children":1720,"icon":1739},"Extending Doctor","\u002Fextending","9.extending\u002F1.index",[1721,1723,1727,1731,1735],{"title":1722,"path":1718,"stem":1719},"Write an extension",{"title":1724,"path":1725,"stem":1726},"Visitors","\u002Fextending\u002Fvisitors","9.extending\u002F2.visitors",{"title":1728,"path":1729,"stem":1730},"Ship with a library","\u002Fextending\u002Fshipping","9.extending\u002F3.shipping",{"title":1732,"path":1733,"stem":1734},"Test a Rule","\u002Fextending\u002Ftesting","9.extending\u002F4.testing",{"title":1736,"path":1737,"stem":1738},"Rule inputs","\u002Fextending\u002Frule-inputs","9.extending\u002F5.rule-inputs","i-lucide-puzzle",{"title":1741,"path":1742,"stem":1743},"H3","\u002Fh3","9.h3",{"title":1745,"path":1746,"stem":1747},"MCP","\u002Fmodel-context-protocol","9.model-context-protocol",{"title":1749,"path":1750,"stem":1751},"Pinia","\u002Fpinia","9.pinia",1796492442413,"1c82e0cf-90da-4346-b049-6ae71736a6b9"]