Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When I wrote the list in consecutive elements of the first end of the list wrapped in p tags. #17

Closed
cutsea110 opened this issue Feb 27, 2011 · 1 comment

Comments

@cutsea110
Copy link

write a markdown text as like below,

--- start ---

- a
- b
- c

- x
- y
- z

--- end ----

we get html as

<ul>
<li>a</li>
<li>b</li>
<li><p>c</p></li>
<li>x</li>
<li>b</li>
<li><p>z</p></li>
</ul>

the last element of lists are wraped in p tags.
This is a bug? or spec?
@jgm
Copy link
Owner

jgm commented Feb 27, 2011

I don't think it's a bug. The "spec", to the extent there is one for Markdown, is ambiguous about what to do with this kind of mixed tight-and-loose list.

Pandoc's rule is described here:
http://johnmacfarlane.net/pandoc/README.html#compact-and-loose-lists

A list item followed by blank space is treated as a paragraph, unless the whole list is "compact", in which case none of the items will be treated as paragraphs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants