Esc

Doctor

Every problem comark-linter and Vite Doctor report in a Comark document, one page each. A report's code links here, and each page shows Markdown that triggers it and the same Markdown fixed.

comark-linter reports each problem under a rule, and Vite Doctor reports it under that rule's code.

The core rules catch what Comark forgives: blocks never closed, misspelled components, broken anchors, and unsafe URLs. Each package adds one rule for each kind of problem its plugin puts in meta.issues. That way you can tell them apart in a report and look each one up here.

docs/review.md:8:1 comark/annotate/box-outside-image screenshot "after.png", annotation 2: the box runs past the image edge. Keep x + w and y + h within 100.
txt
pnpm lint-comark "docs/**/*.md"

Or add comark-linter/doctor to doctor.config.ts, and the comark/recommended preset turns every rule on. Vite Doctor has the setup.

Each plugin adds its sentences to meta.issues, as it always has, and also names the rule of each one in meta.issueRules, keyed by the sentence:

const { meta } = await parseMarkdown(markdown, { plugins: [embed()] });
meta.issues; // ["`::embed` 1: `url` must start with https://."]
meta.issueRules; // { "`::embed` 1: `url` must start with https://.": "comark/embed/insecure-url" }
ts

An issue no rule names, such as one from a plugin of your own, is reported as comark/plugin-issue.

CodeRuleWhat it asksSeverity
COMARK0001comark/unclosed-blockClose every :: blockwarning
COMARK0002comark/unknown-componentUse only known componentswarning
COMARK0003comark/malformed-attributesClose { attributes and set each key oncewarning
COMARK0004comark/broken-anchorLink #fragments to a heading or id in the document they namewarning
COMARK0005comark/invalid-frontmatterWrite valid YAML frontmattererror
COMARK0006comark/plugin-issueFix the problems Comark plugins reportwarning
COMARK0007comark/unsafe-urlKeep script URLs out of href and srcerror
COMARK0008comark/duplicate-idGive each element its own idwarning
COMARK0009comark/missing-altDescribe every image in its alt textwarning
COMARK0010comark/empty-linkGive every link textwarning
COMARK0011comark/broken-linkLink files that existwarning
COMARK0012comark/blocked-urlKeep local, private, tunnel, and preview URLs out of linkswarning
COMARK0013comark/dead-urlLink pages that still answerwarning
COMARK0101comark/annotate/unknown-propUse only the props of ::screenshot, ::compare, and ::annotationwarning
COMARK0102comark/annotate/undefined-bindingBind props to data that existswarning
COMARK0103comark/annotate/unsafe-bound-urlBind src and href to http:// or https:// URLswarning
COMARK0104comark/annotate/missing-srcGive every ::screenshot a srcwarning
COMARK0105comark/annotate/missing-altDescribe every ::screenshot in its altwarning
COMARK0106comark/annotate/invalid-hrefLink a screenshot to the http:// or https:// page it capturedwarning
COMARK0107comark/annotate/invalid-viewportWrite viewport as the capture size, like 1440x900warning
COMARK0108comark/annotate/invalid-positionPlace each annotation with x, y, w, h, at, and to from 0 to 100warning
COMARK0109comark/annotate/box-outside-imageKeep each annotation's box inside the imagewarning
COMARK0110comark/annotate/box-as-fractionWrite x, y, w, and h as percentages, not fractionswarning
COMARK0111comark/annotate/unknown-markUse a mark annotate drawswarning
COMARK0112comark/annotate/invalid-colorColor a mark or a figure's ink with a named color or a hex colorwarning
COMARK0113comark/annotate/invalid-sideSet side to left, right, top, or bottomwarning
COMARK0114comark/annotate/invisible-markGive an annotation with mark="none" a sidewarning
COMARK0115comark/annotate/missing-noteWrite a note in every ::annotationwarning
COMARK0116comark/annotate/nested-blockKeep screenshots, compares, and annotations out of notes and captionswarning
COMARK0117comark/annotate/side-notes-overlapLeave room between side notes on one sidewarning
COMARK0118comark/annotate/numbers-overlapLeave room for each annotation's numberwarning
COMARK0119comark/annotate/too-many-annotationsKeep a screenshot or compare to 40 annotationswarning
COMARK0120comark/annotate/annotation-outside-screenshotPut every ::annotation inside a ::screenshotwarning
COMARK0121comark/annotate/compare-contentPut only screenshots inside a ::comparewarning
COMARK0122comark/annotate/compare-screenshot-countGive every ::compare two screenshots, before and afterwarning
COMARK0123comark/annotate/compare-viewport-mismatchCapture both sides of a ::compare at one viewportwarning
COMARK0124comark/annotate/compare-same-imageShow two different images in a ::comparewarning
COMARK0125comark/annotate/invalid-modeSet a compare's mode to columns or sliderwarning
COMARK0126comark/annotate/needs-sideGive an annotation with at or to a sidewarning
COMARK0201comark/cards/invalid-colorWrite a card's color as one of Nuxt UI's colorswarning
COMARK0202comark/cards/href-instead-of-toLink a card with to, not hrefwarning
COMARK0203comark/cards/unsafe-linkKeep script URLs out of a card's toerror
COMARK0204comark/cards/invalid-colsWrite cols as a number from 1 to 6warning
COMARK0205comark/cards/empty-columnsPut a block in every ::columnswarning
COMARK0206comark/cards/unknown-propUse only the props of ::card and ::columnswarning
COMARK0207comark/cards/invalid-variantWrite a card's variant as outline, soft, or subtlewarning
COMARK0301comark/carousel/content-outside-slideKeep a carousel's content inside its :::slide blockswarning
COMARK0302comark/carousel/empty-carouselGive every ::carousel a slidewarning
COMARK0303comark/carousel/invalid-columnsSet columns to 1, 2, or 3warning
COMARK0304comark/carousel/unresolved-bindingBind :zoom and :title to the document or its frontmatterwarning
COMARK0305comark/carousel/slide-outside-carouselKeep :::slide inside a ::carouselwarning
COMARK0306comark/carousel/unknown-propUse only ::carousel's and :::slide's propswarning
COMARK0401comark/charts/unknown-propUse only the props of ::chart and its annotationswarning
COMARK0402comark/charts/missing-tablePut a Markdown table in every ::chartwarning
COMARK0403comark/charts/content-droppedKeep text out of ::chartwarning
COMARK0404comark/charts/too-few-columnsGive a chart's table an x column and a column of numberswarning
COMARK0405comark/charts/unnamed-columnGive every column of a chart's table a headerwarning
COMARK0406comark/charts/duplicate-columnGive each column of a chart's table its own headerwarning
COMARK0407comark/charts/empty-tableGive a chart's table rowswarning
COMARK0408comark/charts/unknown-columnName only the table's columns in x and ywarning
COMARK0409comark/charts/x-in-yKeep the x column out of ywarning
COMARK0410comark/charts/missing-xFill in every row's x valuewarning
COMARK0411comark/charts/non-numeric-valueWrite chart values as plain numberswarning
COMARK0412comark/charts/duplicate-xGive each row its own x valuewarning
COMARK0413comark/charts/unknown-typeUse a type comark-charts drawswarning
COMARK0414comark/charts/non-numeric-xPut numbers on the x of a scatter plotwarning
COMARK0415comark/charts/too-few-seriesGive a dumbbell two or more columns of numberswarning
COMARK0416comark/charts/too-few-rowsGive a line or an area two or more rowswarning
COMARK0417comark/charts/too-many-seriesDraw one column in a pie or a waterfallwarning
COMARK0418comark/charts/invalid-pie-valuesGive a pie a total to divide, with no negative numberswarning
COMARK0419comark/charts/invalid-atPoint every chart annotation at a row with atwarning
COMARK0420comark/charts/unknown-seriesName a column the chart draws in serieswarning
COMARK0421comark/charts/marks-empty-cellMark a cell that holds a numberwarning
COMARK0422comark/charts/spec-with-propsLeave type, x, and y off a chart drawn from a Vega-Lite specwarning
COMARK0423comark/charts/spec-with-annotationsDraw notes on a Vega-Lite chart as layers of its specwarning
COMARK0424comark/charts/invalid-spec-jsonWrite a Vega-Lite spec as one JSON objectwarning
COMARK0425comark/charts/spec-with-dataLeave data out of a Vega-Lite specwarning
COMARK0426comark/charts/unknown-spec-fieldUse the table's headers as a spec's fieldswarning
COMARK0427comark/charts/draw-failedWrite a Vega-Lite spec that Vega-Lite can drawwarning
COMARK0428comark/charts/start-and-endGive every row of a gantt a start and an endwarning
COMARK0429comark/charts/end-before-startEnd every bar of a gantt after it startswarning
COMARK0430comark/charts/too-many-groupsColor a gantt by one column of nameswarning
COMARK0431comark/charts/invalid-labelsPut labels on bar and stacked bar chartswarning
COMARK0432comark/charts/invalid-lineCross a chart with a line at a number on its value axiswarning
COMARK0501comark/chips/invalid-hrefGive every :chip a web address in hrefwarning
COMARK0502comark/chips/invalid-avatarWrite avatar as an image URL, @user, or provider:namewarning
COMARK0503comark/chips/missing-avatarPoint a chip's avatar at an account or image that existswarning
COMARK0504comark/chips/rate-limitedBuild again once unavatar.io answerswarning
COMARK0601comark/code/invalid-rangeWrite line ranges in braces, such as {2-4}warning
COMARK0602comark/code/line-out-of-rangeMark only lines the code block haswarning
COMARK0603comark/code/unknown-frameSet frame to "terminal", "code", or "none"warning
COMARK0604comark/code/invalid-start-lineWrite startLineNumber as a whole numberwarning
COMARK0605comark/code/listed-before-shikiList shiki() before comark-codewarning
COMARK0701comark/diff/unknown-propUse only ::diff's propswarning
COMARK0702comark/diff/undefined-bindingBind ::diff props to data that existswarning
COMARK0703comark/diff/stray-contentPut only the two code blocks inside a ::diffwarning
COMARK0704comark/diff/block-countGive every ::diff two code blocks, before and afterwarning
COMARK0705comark/diff/unified-diffWrite a ::diff as before and after, not as a unified diffwarning
COMARK0706comark/diff/missing-fileName the file a ::diff changeswarning
COMARK0707comark/diff/file-mismatchShow one file in each ::diffwarning
COMARK0708comark/diff/language-mismatchGive both blocks of a ::diff the same languagewarning
COMARK0709comark/diff/invalid-lineWrite line as a whole number from 1warning
COMARK0710comark/diff/too-many-linesKeep each block of a ::diff to 200 lineswarning
COMARK0711comark/diff/no-changeChange something between before and afterwarning
COMARK0801comark/embed/content-droppedKeep content out of ::embedwarning
COMARK0802comark/embed/missing-urlGive every ::embed a urlwarning
COMARK0803comark/embed/insecure-urlEmbed only https:// linkswarning
COMARK0804comark/embed/credentials-in-urlKeep user names and passwords out of embed linkswarning
COMARK0805comark/embed/invalid-startWrite start as whole secondswarning
COMARK0806comark/embed/start-unsupportedSet start only on YouTube and Vimeo videoswarning
COMARK0807comark/embed/card-without-titleGive a link card a titlewarning
COMARK0808comark/embed/unreadable-linkLink a provider's page it can read an ID fromwarning
COMARK0809comark/embed/unknown-propUse only ::embed's propswarning
COMARK2301comark/footnotes/missing-definitionDefine every footnote you referencewarning
COMARK2302comark/footnotes/unused-definitionReference every footnote you definewarning
COMARK2303comark/footnotes/duplicate-definitionDefine each footnote label oncewarning
COMARK0901comark/github/invalid-repoSet references({ repo }) to owner/namewarning
COMARK0902comark/github/unknown-callout-typeUse one of GitHub's five callout typeswarning
COMARK1001comark/icon/missing-nameGive every :icon a namewarning
COMARK1002comark/icon/invalid-nameWrite icon names as set:namewarning
COMARK1003comark/icon/unknown-setDraw icons from a set that existswarning
COMARK1004comark/icon/unknown-iconUse an icon its set haswarning
COMARK1005comark/icon/download-failedPass the icon sets Iconify can't serve in collectionswarning
COMARK1006comark/icon/unknown-propUse only :icon's propswarning
COMARK1101comark/include/missing-srcGive every :include a srcwarning
COMARK1102comark/include/unknown-optionUse only :include's optionswarning
COMARK1103comark/include/remote-fileInclude only local fileswarning
COMARK1104comark/include/path-outside-rootKeep included paths under the rooterror
COMARK1105comark/include/lines-and-regionUse lines or region, not bothwarning
COMARK1106comark/include/include-cycleDon't let a file include itselfwarning
COMARK1107comark/include/too-deepNest includes no deeper than depthwarning
COMARK1108comark/include/read-failedInclude a file that can be readwarning
COMARK1109comark/include/file-not-foundInclude a file that existswarning
COMARK1110comark/include/invalid-linesWrite lines as a range inside the filewarning
COMARK1111comark/include/missing-regionName a region the file markswarning
COMARK1112comark/include/unclosed-regionEnd every #region with #endregionwarning
COMARK1113comark/include/open-block-in-partialClose a partial's :: blocks inside itwarning
COMARK1114comark/include/misplaced-includeWrite :include alone on its own linewarning
COMARK1201comark/steps/invalid-levelSet level from 2 to 6warning
COMARK1202comark/steps/content-before-stepsStart ::steps with its first step's headingwarning
COMARK1203comark/steps/no-stepsStart each step with a heading at level, or use one numbered listwarning
COMARK1204comark/steps/unknown-propUse only ::steps's level propwarning
COMARK1301comark/tabs/content-outside-tabPut everything in ::tabs inside a :::tabs-itemwarning
COMARK1302comark/tabs/content-in-code-groupPut only code blocks in ::code-groupwarning
COMARK1303comark/tabs/empty-tabsGive every ::tabs a tabwarning
COMARK1304comark/tabs/missing-labelLabel every tabwarning
COMARK1305comark/tabs/duplicate-labelGive each tab in a block its own labelwarning
COMARK1306comark/tabs/stray-tabs-itemKeep :::tabs-item inside ::tabswarning
COMARK1307comark/tabs/unknown-propUse only the props of ::tabs and :::tabs-itemwarning
COMARK1308comark/tabs/no-manager-formWrite npm2yarn commands every package manager haswarning
COMARK1309comark/tabs/no-npm-commandWrite an npm2yarn block in npm commandswarning
COMARK1401comark/badge/invalid-colorWrite a badge's color as one of Nuxt UI's colorswarning
COMARK1402comark/badge/empty-badgeGive every :badge textwarning
COMARK1403comark/badge/unknown-propUse only :badge's color propwarning
COMARK2501comark/outline/content-droppedKeep content out of ::tocwarning
COMARK2502comark/outline/invalid-depthWrite depth as a whole number from 2 to 6warning
COMARK2503comark/outline/no-headingsGive a ::toc headings to listwarning
COMARK2504comark/outline/unknown-propUse only ::toc's propswarning
COMARK3901comark/media/unplayable-srcLink a video or audio file a browser playswarning
COMARK3902comark/media/missing-labelDescribe every video and audio filewarning
COMARK3903comark/media/poster-on-audioKeep poster off audiowarning
COMARK3904comark/media/autoplay-without-mutedMute a file that plays by itselfwarning
COMARK3905comark/media/unknown-propUse only a media file's optionswarning
COMARK3301comark/qr/missing-valueGive every :qr a valuewarning
COMARK3302comark/qr/value-too-longKeep a :qr value short enough to encodewarning
COMARK3303comark/qr/content-droppedKeep text out of :qr's bracketswarning
COMARK3304comark/qr/unknown-propUse only :qr's propswarning
COMARK3801comark/colors/missing-listGive every ::palette a list of name: color lineswarning
COMARK3802comark/colors/content-droppedKeep everything but the list out of ::palettewarning
COMARK3803comark/colors/unreadable-lineWrite each palette line as name: colorwarning
COMARK3804comark/colors/invalid-colorWrite palette colors in a form it can drawwarning
COMARK3805comark/colors/unknown-propGive ::palette no propswarning
COMARK1501comark/diagrams/draw-failedWrite a diagram's source so Kroki can draw itwarning
COMARK1502comark/diagrams/server-unreachableReach the Kroki server while buildingwarning
COMARK2201comark/cast/missing-castGive every ::cast a castwarning
COMARK2202comark/cast/unknown-propUse only ::cast's propswarning
COMARK2203comark/cast/invalid-modeSet mode to screen or logwarning
COMARK2204comark/cast/src-and-codeGive a ::cast a src or a code block, not bothwarning
COMARK2205comark/cast/remote-fileRead casts from local fileswarning
COMARK2206comark/cast/path-outside-rootKeep cast paths under the rooterror
COMARK2207comark/cast/read-failedPoint src at a file that can be readwarning
COMARK2208comark/cast/file-not-foundPoint src at a file that existswarning
COMARK2209comark/cast/invalid-headerStart a cast with an asciinema v2 or v3 headerwarning
COMARK2210comark/cast/invalid-eventWrite every line after the header as an eventwarning
COMARK2211comark/cast/no-outputRecord a cast with outputwarning
COMARK3201comark/code-notes/missing-notesFollow a fence with markers by a numbered listwarning
COMARK3202comark/code-notes/marker-without-noteGive every marker a notewarning
COMARK3203comark/code-notes/note-without-markerGive every note a marker in the codewarning
COMARK3204comark/code-notes/shiki-orderPut comark-code-notes after shikiwarning
COMARK3601comark/tests/missing-reportGive every ::tests a src or an XML fencewarning
COMARK3602comark/tests/content-droppedUse src or a fence in ::tests, not bothwarning
COMARK3603comark/tests/remote-srcPoint src at a local filewarning
COMARK3604comark/tests/outside-rootKeep the report under the rootwarning
COMARK3605comark/tests/file-not-foundPoint src at a report that existswarning
COMARK3606comark/tests/read-failedGive ::tests a report it can readwarning
COMARK3607comark/tests/malformed-xmlFix the report's XMLwarning
COMARK3608comark/tests/not-junitShow a JUnit report in ::testswarning
COMARK3609comark/tests/unknown-propUse only ::tests' propswarning
COMARK3101comark/fields/missing-nameGive every ::field a namewarning
COMARK3102comark/fields/unknown-propUse only ::field's propswarning
COMARK3103comark/fields/description-ignoredWrite a field's description oncewarning
COMARK1601comark/metrics/invalid-betterWrite better as lower or higherwarning
COMARK1602comark/metrics/missing-numberGive :delta its from and to, and :progress its valuewarning
COMARK1603comark/metrics/invalid-numberWrite from, to, and value as bare numberswarning
COMARK1604comark/metrics/invalid-maxWrite max as a number above 0warning
COMARK1605comark/metrics/value-out-of-rangeKeep a :progress value between 0 and maxwarning
COMARK1606comark/metrics/missing-tablePut a table inside ::statswarning
COMARK1607comark/metrics/content-droppedKeep everything but the table out of ::statswarning
COMARK1608comark/metrics/column-countGive a ::stats table three columns, or two with tileswarning
COMARK1609comark/metrics/non-numeric-cellWrite a ::stats row's before and after as numberswarning
COMARK1610comark/metrics/unit-mismatchWrite a ::stats row's before and after in one unitwarning
COMARK1611comark/metrics/unknown-propUse only the props of :delta, :progress, and ::statswarning
COMARK2001comark/file-tree/list-instead-of-fenceWrite a ::file-tree in a fenced block, not a listwarning
COMARK2002comark/file-tree/empty-treeGive every ::file-tree at least one entrywarning
COMARK2003comark/file-tree/content-droppedPut only one fenced block inside ::file-treewarning
COMARK2004comark/file-tree/unknown-propGive ::file-tree no propswarning
COMARK2701comark/details/missing-summaryGive every ::details a summarywarning
COMARK2702comark/details/content-outside-itemPut everything in ::accordion inside an :::accordion-itemwarning
COMARK2703comark/details/empty-accordionGive every ::accordion an itemwarning
COMARK2704comark/details/missing-labelLabel every accordion itemwarning
COMARK2705comark/details/invalid-default-valueOpen accordion items by their position from 0warning
COMARK2706comark/details/invalid-typeWrite an accordion's type as single or multiplewarning
COMARK2707comark/details/stray-accordion-itemKeep :::accordion-item inside ::accordionwarning
COMARK2708comark/details/empty-collapsiblePut content in every ::collapsiblewarning
COMARK2709comark/details/unknown-propUse only the props of ::details, ::accordion, and ::collapsiblewarning
COMARK1701comark/critic/unclosed-markClose every CriticMarkup mark in its paragraphwarning
COMARK1702comark/critic/missing-arrowWrite ~> between the old and new text of {~~ ~~}warning
COMARK1703comark/critic/invalid-modeSet comark-critic's mode to view, accept, or rejectwarning
COMARK2801comark/properties/invalid-valueWrite each shown key as text, a number, a link, or a list of themwarning
COMARK2802comark/properties/content-droppedKeep content out of ::propertieswarning
COMARK2803comark/properties/nothing-to-showGive ::properties a key to showwarning
COMARK2804comark/properties/unknown-propWrite ::properties without propswarning
COMARK3001comark/sources/invalid-citeWrite source numbers inside :citewarning
COMARK3002comark/sources/unknown-sourceCite only sources ::sources listswarning
COMARK3003comark/sources/missing-listGive ::sources a numbered listwarning
COMARK3004comark/sources/second-listKeep one ::sources per documentwarning
COMARK3005comark/sources/missing-linkLink every sourcewarning
COMARK3006comark/sources/content-droppedKeep only the list inside ::sourceswarning
COMARK3007comark/sources/unknown-propUse only ::sources' propswarning
COMARK2601comark/table/empty-blockGive every ::table a file or a table to showwarning
COMARK2602comark/table/content-droppedGive ::table a src or content, not bothwarning
COMARK2603comark/table/remote-srcRead tables only from local fileswarning
COMARK2604comark/table/path-outside-rootKeep a table's src under the rooterror
COMARK2605comark/table/file-not-foundRead a table from a file that existswarning
COMARK2606comark/table/read-failedRead a table from a file that can be readwarning
COMARK2607comark/table/unknown-formatGive a table CSV, TSV, or JSONwarning
COMARK2608comark/table/invalid-jsonWrite a table's JSON so it parseswarning
COMARK2609comark/table/json-not-rowsWrite a table's JSON as an array of objectswarning
COMARK2610comark/table/unclosed-quoteClose every quoted cellwarning
COMARK2611comark/table/no-rowsGive a table a header and a row of datawarning
COMARK2612comark/table/uneven-rowGive every row one cell per columnwarning
COMARK2613comark/table/base-outside-rootSet base to a folder under the rootwarning
COMARK2614comark/table/unknown-propUse only ::table's propswarning
COMARK2615comark/table/unknown-toneColor a cell with success, warning, error, or infowarning
COMARK2616comark/table/partial-toneFill the cell with its tone spanwarning
COMARK2901comark/xref/duplicate-labelGive each figure and table its own labelwarning
COMARK2902comark/xref/inline-figurePut a labeled image on a line of its ownwarning
COMARK2903comark/xref/missing-idGive every :ref an idwarning
COMARK2904comark/xref/unknown-labelPoint :ref at a label in the documentwarning
COMARK2905comark/xref/ref-contentKeep text out of :refwarning
COMARK4001comark/quiz/no-optionsWrite a question's or poll's options as a task listerror
COMARK4002comark/quiz/no-correct-optionMark a question's right option [x]error
COMARK4003comark/quiz/correct-in-pollLeave every poll option uncheckederror
COMARK4004comark/quiz/missing-answerGive every ::recall an #answererror
COMARK4005comark/quiz/missing-idGive every quiz block an #idwarning
COMARK4006comark/quiz/duplicate-idGive each quiz block its own #iderror
COMARK4007comark/quiz/longest-correctKeep the right option about as long as the otherswarning
COMARK4008comark/quiz/position-optionWrite out an option instead of pointing at others by placewarning
COMARK4009comark/quiz/missing-rationaleSay why each wrong option is wrong in a > linewarning
COMARK4010comark/quiz/line-break-optionStart an option's rationale with >warning
COMARK4011comark/quiz/swallowed-slotLeave a blank line before #explain, #hint, and #answererror
COMARK4012comark/quiz/too-many-optionsKeep a block to six optionswarning
COMARK4013comark/quiz/unknown-propUse only the props of ::question, ::poll, and ::recallwarning
COMARK4014comark/quiz/unknown-slotUse only the slots of ::question and ::recallwarning
COMARK4015comark/quiz/invalid-closesWrite a poll's closes as an ISO datewarning
COMARK4016comark/quiz/nested-blockKeep quiz blocks out of each otherwarning