Module

PuduLangDocgen.Build.Checks

View source

Whole-site validation of fragments, outputs, and diagnostic levels

Functions

Name Description
fragments Fragment links that name no element of their target page. Links to files other than pages are not checked for fragments; links to missing files were reported while rendering.
anchors Every `id` attribute value in HTML.
outputs Output paths that are not portable, collide ignoring case, or put a file where a folder is.
ruled Diagnostics with configured levels applied: `off` drops a code, `info`, `warning`, and `error` set its severity, and with `strict` every remaining warning becomes an error.

fragments

fn fragments(pages: &Array[Docgen.Page]) -> Array[Docgen.Diagnostic]

Fragment links that name no element of their target page. Links to files other than pages are not checked for fragments; links to missing files were reported while rendering.

Parameters

pages
&Array[Docgen.Page]

Returns

Array[Docgen.Diagnostic]

View source

anchors

fn anchors(html: Str) -> Array[Str]

Every id attribute value in HTML.

Parameters

html
Str

Returns

Array[Str]

View source

outputs

fn outputs(paths: &Array[Str]) -> Array[Docgen.Diagnostic]

Output paths that are not portable, collide ignoring case, or put a file where a folder is.

Parameters

paths
&Array[Str]

Returns

Array[Docgen.Diagnostic]

View source

ruled

fn ruled(diagnostics: &Array[Docgen.Diagnostic], rules: &Array[(Str, Str)], strict: Bool) -> Array[Docgen.Diagnostic]

Diagnostics with configured levels applied: off drops a code, info, warning, and error set its severity, and with strict every remaining warning becomes an error.

Parameters

diagnostics
&Array[Docgen.Diagnostic]
rules
&Array[(Str, Str)]
strict
Bool

Returns

Array[Docgen.Diagnostic]

View source