Skip to content

Commit 7b83eac

Browse files
authored
Markdown Docs: specify necessary indent (#51456)
Rationale: currently, the Markdown documentation specifies the necessary indent for code blocks and lists only. As there are people out there, who indent their lines by only two spaces (or whatever amount) documenting the indent could help in finding the reason for malformed Markdown. See #45622. For an example where this problem occurred see oscar-system/Oscar.jl#1369 (comment).
1 parent 4119dcf commit 7b83eac

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

stdlib/Markdown/docs/src/index.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,8 @@ A header line can contain any inline syntax in the same way as a paragraph can.
153153

154154
### Code blocks
155155

156-
Source code can be displayed as a literal block using an indent of four spaces as shown in the
157-
following example.
156+
Source code can be displayed as a literal block using an indent of four spaces or one tab as shown
157+
in the following example.
158158

159159
```
160160
This is a paragraph.
@@ -298,7 +298,8 @@ aside from the `:` character that is appended to the footnote label.
298298
299299
[^note]:
300300
301-
Named footnote text containing several toplevel elements.
301+
Named footnote text containing several toplevel elements
302+
indented by 4 spaces or one tab.
302303
303304
* item one
304305
* item two
@@ -357,6 +358,7 @@ They can be defined using the following `!!!` syntax:
357358
!!! note
358359
359360
This is the content of the note.
361+
It is indented by 4 spaces. A tab would work as well.
360362
361363
!!! warning "Beware!"
362364

0 commit comments

Comments
 (0)