mdsmith
Esc
    v0.52.0 GitHub
    MDS041 structural ready

    MDS041: no-inline-html

    Raw HTML tags in Markdown are not allowed; use a Markdown construct or an mdsmith directive instead.

    # Config

    Enable with default settings (empty allowlist, comments permitted):

    rules:
      no-inline-html: true

    Enable with specific tags allowed:

    rules:
      no-inline-html:
        allow: [kbd, sub, sup]
        allow-comments: true

    Disable:

    rules:
      no-inline-html: false

    # Settings

    SettingTypeDefaultDescription
    allowlist of strings[]Tag names that are permitted (replaces, not appended).
    allow-commentsbooltrueWhether HTML comments (<!-- ... -->) are allowed.

    # Examples

    # Bad

    # Title
    
    text <span>x</span> text

    # Good

    # Title
    
    Press <kbd>Enter</kbd> to continue.

    # What is not flagged

    • Fenced and indented code blocks containing HTML
    • Inline code spans
    • Autolinks (<https://example.com>)
    • mdsmith directives (<?name ... ?>) — block forms are parsed as ProcessingInstruction nodes; inline forms are skipped because they start with <?
    • HTML entities in text (&amp;, &#x2014;)
    • Closing tags (</div>) — the matching opening tag already produced a diagnostic

    # Meta-Information

    • ID: MDS041
    • Name: no-inline-html
    • Status: ready
    • Default: disabled (opt-in)
    • Fixable: no
    • Implementation: source
    • Category: structural
    • markdownlint: MD033 (no-inline-html)
    • rumdl: MD033 (no-inline-html)
    • mado: MD033 (no-inline-html)