Expand description
HTML5 conformance checking with browser-style error recovery.
check/check_with_options combine six finding sources, in order:
HTML parser diagnostics, RELAX NG schema (content-model) validation,
Schematron-style assertion (co-constraint) checking,
<script type="importmap"|"speculationrules"> JSON content validation
(src/scripts.rs — a value/content-format check like the RELAX NG
datatypes, just on element text content instead of an attribute), and
<meta http-equiv="Content-Security-Policy"> enforcement against
inline script/style content elsewhere in the document
(src/csp_enforcement.rs — a genuine cross-element check needing a
real CSP source-list parser, not expressible as a rules/*.sch rule
or a w:* datatype), and table cell-grid integrity
(src/table_integrity.rs — laying a table out over its
colspan/rowspan values needs mutable state carried forward across
cells, which XPath 1.0 has no way to express).
Structs§
- Check
Options - Options that control which diagnostics are included in a check report.
- Check
Report - The result of checking one HTML document.
- Finding
- A single conformance or parser finding.
- Source
Location - A source location in the checked HTML input.
Enums§
- Check
Error - A technical failure that prevented a document from being checked.
- Severity
- The severity of a conformance finding.
Functions§
- check
- Checks a complete HTML document with the default options.
- check_
with_ options - Checks a complete HTML document with explicit options.