Opened 7 years ago
Last modified 6 years ago
#2738 assigned defect (bug)
Plugin Directory: Single line breaks in readme.txt should be ignored
Reported by: | yo35 | Owned by: | tellyworth |
---|---|---|---|
Milestone: | Plugin Directory v3.0 | Priority: | normal |
Component: | Plugin Directory | Keywords: | 2nd-opinion |
Cc: |
Description
In plugin description pages, a <br>
tag is introduced in the page each time there is a line break in the readme.txt file. This goes against the usual Markdown behavior (see https://en.wikipedia.org/wiki/Markdown#Example).
Change History (8)
#3
@
7 years ago
Consider this example:
I am a very very long sentence that belongs to a single paragraph but I am split on several lines in the readme.txt file so that I remains easily readable and editable in plain text mode.
This would be rendered as follows:
<p>I am a very very long sentence that belongs to a single paragraph but I am split<br/> on several lines in the readme.txt file so that I remains easily readable and<br/> editable in plain text mode.</p>
The expected behavior -- according to the usual Markdown behavior -- would be to have it rendered without the two <br/> tags. By "usual Markdown behavior", I mean:
- what is presented on the Markdown Wikipedia page: https://en.wikipedia.org/wiki/Markdown#Example,
- what is advised on the official Markdown website: https://daringfireball.net/projects/markdown/syntax#p,
- what is implemented in several websites that use Markdown, including GitHub for instance.
#4
@
7 years ago
- Summary changed from Line breaks in readme.txt should be ignored to Plugin Directory: Single line breaks in readme.txt should be ignored
This is expected behavior in WordPress however :) If you wrote that example in WP's Post Editor, it would introduce line breaks.
Single line break == br
Double line break == p
This is not Markdown, it's nearly markdown, and we know that causes some confusion, but expecting full markdown behavior from your readme.txt is going to end badly.
I'm leaning towards a wontfix here since it's a part of the readme parser and being on WP now and not bbPress.
#5
@
7 years ago
In case of a wontfix, the readme.txt sample file (https://wordpress.org/plugins/files/2016/06/readme.txt) should be updated, as it heavily uses single line breaks à-la Markdown.
No, line breaks in the readme.txt result in paragraphs, not BR tags.
You need to provide examples of the problem for this to be seen.