Problem restarting list after paragraph #55

Closed
opened 2026-01-29 14:23:37 +00:00 by claunia · 0 comments
Owner

Originally created by @christophano on GitHub (Sep 9, 2016).

The following markdown:

1.   First item

Some text

2.   Second item

should render as:

<ol>
<li>First item</li>
</ol>
<p>Some text</p>
<ol start="2">
<li>Second item</li>
</ol>

but instead renders as:

<ol>
  <li>
    First item
  </li>
</ol>
<p>
  Some text
</p>
<p>
  2. Second item
</p>

This issue is related to the change in CommonMark 0.26 where starting a list after a paragraph is only allowed using 1. to start to list.
For some reason, Markdig is not respecting the blank line after the paragraph to allow continuation.

Originally created by @christophano on GitHub (Sep 9, 2016). The following markdown: ``` 1. First item Some text 2. Second item ``` should render as: ``` <ol> <li>First item</li> </ol> <p>Some text</p> <ol start="2"> <li>Second item</li> </ol> ``` but instead renders as: ``` <ol> <li> First item </li> </ol> <p> Some text </p> <p> 2. Second item </p> ``` This issue is related to the change in CommonMark 0.26 where starting a list after a paragraph is only allowed using `1.` to start to list. For some reason, Markdig is not respecting the blank line after the paragraph to allow continuation.
claunia added the bug label 2026-01-29 14:23:37 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/markdig#55