[GH-ISSUE #1129] MD029: Ordered list with Note block #617

Closed
opened 2026-03-03 01:28:29 +03:00 by kerem · 1 comment
Owner

Originally created by @SerTetora on GitHub (Feb 15, 2024).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/1129

I encountered an issue with Markdown rendering where I have an ordered list in my Markdown file, separated by a note block. Despite the correct content, it generates the MD029 warning.

Original:

1. Fist item:

> [!NOTE]
> Some note

2. second item

It is rendered as

  1. Fist item:

Note

Some note

  1. second item

However, this setup triggers the MD029 warning. According to MD029, a solution is proposed to indent the code block so it becomes part of the preceding list item as intended:

1. Fist item:

    > [!NOTE]
    > Some note

2. second item

However, after applying this solution, the note is rendered incorrectly:

  1. Fist item:

    Note

    Some note

  2. second item

Originally created by @SerTetora on GitHub (Feb 15, 2024). Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/1129 I encountered an issue with Markdown rendering where I have an ordered list in my Markdown file, separated by a note block. Despite the correct content, it generates the MD029 warning. Original: ``` 1. Fist item: > [!NOTE] > Some note 2. second item ``` It is rendered as 1. Fist item: > [!NOTE] > Some note 2. second item However, this setup triggers the MD029 warning. According to [MD029](https://github.com/DavidAnson/markdownlint/blob/v0.33.0/doc/md029.md), a solution is proposed to indent the code block so it becomes part of the preceding list item as intended: ``` 1. Fist item: > [!NOTE] > Some note 2. second item ``` However, after applying this solution, the note is rendered incorrectly: 1. Fist item: > [!NOTE] > Some note 2. second item
kerem 2026-03-03 01:28:29 +03:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@DavidAnson commented on GitHub (Feb 15, 2024):

You'll probably want to suppress that warning in this case. It seems that GitHub only recognizes notes when they are fully left-aligned. But when that's done, it creates two separate lists and the second list begins with 2 instead of 1, so the markdownlint warning is correct. GitHub allows you to start a list with a different number than 1 which is why this looks OK rendered.

<!-- gh-comment-id:1946646687 --> @DavidAnson commented on GitHub (Feb 15, 2024): You'll probably want to suppress that warning in this case. It seems that GitHub only recognizes notes when they are fully left-aligned. But when that's done, it creates two separate lists and the second list begins with 2 instead of 1, so the markdownlint warning is correct. GitHub allows you to start a list with a different number than 1 which is why this looks OK rendered.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/markdownlint#617
No description provided.