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

Table within list doesn't render correctly #182

Closed
ajeetdsouza opened this issue Apr 9, 2021 · 2 comments · Fixed by #183
Closed

Table within list doesn't render correctly #182

ajeetdsouza opened this issue Apr 9, 2021 · 2 comments · Fixed by #183

Comments

@ajeetdsouza
Copy link

In the README of my crate, a Markdown table placed under a list element doesn't render correctly, even with the correct indentation. This works fine on GitHub, and it would be nice if comrak was able to support this too.

For context, look at the Environment Variables section in both of these:

GitHub README: https://github.com/ajeetdsouza/zoxide#environment-variables
crates.io README (rendered with Comrak): https://crates.io/crates/zoxide


The following is an example of a table within a list in Markdown:

- Root 1
  - Item 1
  - Item 2:
    | OS          | Path                                     | Example                                    |
    | ----------- | ---------------------------------------- | ------------------------------------------ |
    | Linux / BSD | `$XDG_DATA_HOME` or `$HOME/.local/share` | `/home/alice/.local/share`                 |
    | macOS       | `$HOME/Library/Application Support`      | `/Users/Alice/Library/Application Support` |
    | Windows     | `{FOLDERID_RoamingAppData}`              | `C:\Users\Alice\AppData\Roaming`           |

It should render this way:

  • Root 1
    • Item 1
    • Item 2:
      OS Path Example
      Linux / BSD $XDG_DATA_HOME or $HOME/.local/share /home/alice/.local/share
      macOS $HOME/Library/Application Support /Users/Alice/Library/Application Support
      Windows {FOLDERID_RoamingAppData} C:\Users\Alice\AppData\Roaming
@kivikakk
Copy link
Owner

kivikakk commented Apr 9, 2021

Thanks for the report. It looks like this change needs to be carried across to Comrak: github/cmark-gfm@ef13dc5

@ajeetdsouza
Copy link
Author

That was fast, thank you!

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

Successfully merging a pull request may close this issue.

2 participants