hyogen-md

0.10.0

Error and Warning Codes

All codes use English message templates. Use formatDiagnosticLog or formatMessage to format them.

Errors (render aborts)

CodeWhen
file_not_foundinclude, component, or extend target does not exist
frontmatter_too_largeFront matter source exceeds 64 KB
duplicate_component_aliasSame component … as alias registered twice in one file
alias_collisionComponent as name collides with a variable or parent registration
forbidden_property_accessAccess to a dangerous key (__proto__, prototype, constructor, __defineGetter__)
parse_errorSyntax outside the whitelist, malformed DSL, or missing client loader
component_multiline_outputComponent rendered more than one line (components must be single-line)
server_context_on_clientserverContext passed to renderClient
load_failedLoader failed for a reason other than not found

Example error log:

[hyogen:error] file_not_found
  path: ./missing.md
  from: ./page.md
  via: include

Warnings (render continues)

CodeWhen
circular_includeCircular include / component / extend reference — skipped
nest_limit_exceededif / each structural nesting exceeds 20 — block skipped
extend_in_componentextend inside a component — skipped
prop_type_mismatchComponent prop type does not match — value becomes undefined
prop_missingRequired component prop missing — value becomes undefined
prop_unknownUnknown prop key passed to component — ignored
suspicious_context_valueContext value looks dangerous (XSS patterns) — not modified

suspicious_context_value reasons

ReasonDetects
contains_html_script_tag<script / </script>
contains_event_handleronerror=, onclick=, onload=
contains_dangerous_schemejavascript:, vbscript:
contains_embed_tag<iframe, <object, <embed
contains_meta_refresh<meta … http-equiv

Warnings are collected in RenderResult.warnings and BuildResult.warnings. Errors are thrown as HyogenError.