Spec Order List Needs to update

The spec is outdated for order list.

  1. Main item
    a. Sub item
    b. Sub item
  2. Second main item
  3. Third main item

GitHub and others works this way even your forum, 2 spaces after the line doesn’t make sense to workaround this problem.

GitHub Link: Spec Order List needs to update · Issue #266 · commonmark/commonmark.js · GitHub
Spec: commonmark.js demo

Zero of the parsers that return results in BabelMark 3 behave according to your expectations, including GitHub Flavored Markdown (GFM), Pandoc and CommonMark. Neither does the original Markdown, which you can try here: Daring Fireball: Markdown Web Dingus.

In fact, it’s not true that this forum or GitHub comments behave as you expect. As you can see in the HTML output shown in your linked CommonMark.js demo, or in the HTML at the above BabelMark 3 link, “a. Sub item” and “b. Sub item” are not actually being parsed or rendered as list items in a sublist of item 1. They are just continuations of item 1’s paragraph “Main item”, but with hard line breaks in the rendering where there are “soft line breaks” in the source. As the preceding link explains, soft line breaks within a the paragraph in the source can be rendered as hard or soft line breaks in the output, at the renderer’s discretion.

For example:

Main item
a. Not really a list item
b. Not really a list item.
33. Still not a list item.
34. Just continuation of the same paragraph with intervening "soft line breaks", which should be evident in the way this "item" soft wraps in the browser rendering. 

renders in this forum as:


Main item
a. Not really a list item
b. Not really a list item.
33. Still not a list item.
34. Just continuation of the same paragraph with intervening “soft line breaks”, which should be evident in the way this “item” soft wraps in the browser rendering.


2 Likes