Warnings when using an include within an admonition
Open
Nobody has claimed this yet.
C-bug
- Dominant language
- Rust
- Stars
- 22.2k
- Forks
- 1.9k
- PR merge metrics
- PR metrics pending
Description
Problem
The following causes warnings but renders correctly:
> [!TIP]
> <details><summary>Click to open</summary>{{#include assets/tables/any_exp.html}}</details>
WARN unclosed HTML tag `<details>` found in `zoktai/any.md` while exiting BlockQuote(Some(Tip))
HTML tags must be closed before exiting a markdown element.
WARN unexpected HTML end tag `</details>` found in `zoktai/any.md`
Check that the HTML tags are properly balanced.
All tags are properly closed but are not detected as such, replacing the include with plain text resolves the warnings.
Version
mdBook 0.5.0
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the warning with zoktai/any.md, assets/tables/any_exp.html, and the shown admonition/include snippet under mdBook 0.5.0. Trace include handling and HTML-tag validation first; done means the example renders without the unclosed or unexpected tag warnings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- documentation
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100