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

List under a list does not indent #615

Open
abhishekchandran opened this issue Nov 1, 2018 · 4 comments
Open

List under a list does not indent #615

abhishekchandran opened this issue Nov 1, 2018 · 4 comments
Assignees

Comments

@abhishekchandran
Copy link

abhishekchandran commented Nov 1, 2018

When a list under a list is created in the markdown, it does not indent.

This is how list in GitHub behaves

List with Sub-lists

  • 1

    • 1.1
    • 1.2
  • 2

    • 2.1
    • 2.2

And this is how showdown renders

showdown demo

@tivie
Copy link
Member

tivie commented Nov 3, 2018

According to markdown spec, in lists, sub-blocks need to be indented 4 spaces. That includes sub-lists:

- foo
    - bar

However, almost all implementations (for historical reasons) accept 2 space indentations in sublists.

You can enabled this feature in showdown with option disableForced4SpacesIndentedSublists

@tivie
Copy link
Member

tivie commented Nov 4, 2018

I just noticed that with the last update the Demo Page is broken (options won't stick). I will fix that as fast as possible

@fabiospampinato
Copy link

fabiospampinato commented Jan 30, 2019

@tivie this is still broken for me too. I'm setting disableForced4SpacesIndentedSublists to true but still the following:

- foo
  - bar
    - baz
      - qux

gets rendered as:

screen shot 2019-01-30 at 02 32 08

@avand
Copy link

avand commented Apr 17, 2019

I'm in the same boat here too. It looks like this Markdown:

- Parent
  - First child
    - Grandchild
  - Second child

Is rendering as this:

image

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

No branches or pull requests

5 participants