HTML Element Auto-converted
Q-2-9 — HTML Element Auto-converted
An HTML element written directly in markdown was passed through as raw HTML. Warning only.
What this means
Writing HTML directly in markdown — “naked” HTML — is not a supported form in Quarto Markdown. Quarto does not reject it: it passes the element through unchanged and emits this warning so the implicit conversion is visible.
How it is passed through depends on where the tag sits:
- A tag that opens a line and names a block-level element
(
<div>,<details>,<summary>,<section>,<table>, …) becomes a raw HTML block. It is emitted on its own, not wrapped in a paragraph — a<div>inside a<p>is invalid HTML, and a browser would silently restructure the page around it. - Anything else — a tag in the middle of a sentence, or an inline
element such as
<span>,<b>or<img>— becomes a raw HTML inline and stays inside its paragraph.
Why this happens
The pattern shows up whenever raw HTML appears in markdown text:
- A custom HTML element copied from elsewhere.
- A
<span>or<div>used for styling. - Embedded widget markup.
How to fix
The warning does not block the build, so no action is strictly required. To silence it, use one of the explicit forms.
For a block, either a raw-HTML block:
```{=html}
<details class="checksums-section">
<summary>SHA-256 checksums</summary>
```
or — usually better, when all you want is a container with attributes — a Quarto div, which is native markdown and works in every output format:
::: {.checksums-section}
Content here.
:::
For an inline, Pandoc’s raw-attribute form:
`<custom-tag>content</custom-tag>`{=html}