question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Numbered list syntax not properly supported

See original GitHub issue

Prerequisites

Issue description

Only the first “bullet” should define the list bullet type. Markdown-PDF doesn’t handle the case where the first bullet is a number and the following bullets are hyphens.

Steps to reproduce

Expected behavior:

One way to format numeric lists is:

1. Item One
- Item Two
- Item Three

…and by Markdown definition, it should render as:

1. Item One
2. Item Two
3. Item Three

Actual behavior:

Renders as:

1. Item One
• Item Two
• Item Three

Input

If your markdown document does not contain sensitive information, it is easier to diagnose with the exact contents of the file. You can create a gist of the file and paste the link here: https://gist.github.com

Versions

You can get this information from copy and pasting the output of atom --version and apm --version from the command line. Also, please include the OS and what version of the OS you’re running.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
BlueHatbRitcommented, May 29, 2018

I’ve just tried this via Showdown’s demo editor as well and it renders the actual behavior lists. Showdown implements the original markdown spec by John Gruber.

We then have CommonMark which seems to have support from GitHub, but GitHub then have GitHub Flavoured Markdown (GFM) which is a further extension of CommonMark.

There is scope to add multiple markdown flavours into mdpdf, this would be no problem but we’d need to find suitable modules which would handle this. While the dream is to later on build out mdpdf’s own md->html converter for better control, it wouldn’t be feasible for three modules without more contributors. If we’re able to identify a good module for handling md->html for GFM then I’d be happy to give it a test and see if we can fit it in.

0reactions
travscommented, May 28, 2018

@BlueHatbRit From what I can tell, they use GFM in the preview. I checked the spec of GFM though, and actually the behaviour of mdpdf/showdown is correct, and there is a bug in markdown-preview rendering instead.

The spec is here. It looks like they’re not fixing bugs over there right now though, unfortunately

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bulleted and Numbered Lists - Punctuation - Purchase College
Numbered or bulleted items in a list should be of relatively equal weight or value. ... Each list item is lowercased, and there...
Read more >
Checking consistency in numbered lists and bulleted lists.
There are five important things to watch for in numbered and bulleted lists: inconsistent capitalization. Inconsistent punctuation;; Sometimes ...
Read more >
Create a bulleted or numbered list - Microsoft Support
To start a numbered list, type 1, a period (.), a space, and some text. Word will automatically start a numbered list for...
Read more >
Can't start a numbered list on a number other than 1
EDIT: When I wrote this post (June 2012), it was not possible to start a numbered list from something other-than 1. However, you...
Read more >
3.3 Lists – Technical Writing Essentials
Bullet Lists : use when order of listed items is not important ... are clearly and correctly expressed in a formal and precise...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found