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

nested lists not rendering properly #365

Closed
crowlKats opened this issue Feb 10, 2024 · 1 comment
Closed

nested lists not rendering properly #365

crowlKats opened this issue Feb 10, 2024 · 1 comment

Comments

@crowlKats
Copy link

it seems nested lists arent actually nesting, and are just flat

with comrak:
Screenshot 2024-02-10 at 14 16 31

with deno-gfm:
Screenshot 2024-02-10 at 14 16 38

md used:

## Differences with zx

1. Cross platform shell.
  - Makes more code work on Windows.
  - Allows exporting the shell's environment to the current process.
  - Uses [deno_task_shell](https://github.com/denoland/deno_task_shell)'s parser.
1. Minimal globals or global configuration.
  - Only a default instance of `$`, but it's not mandatory to use this.
1. No custom CLI.
1. Good for application code in addition to use as a shell script replacement.
1. Named after my cat.
@kivikakk
Copy link
Owner

As always, a good start is to try the official commonmark dingus. You'll note comrak matches its output; deno-gfm is not quite right here.

See the CommonMark spec on list items. tl;dr your sublists aren't indented enough to be considered a continuation of the ordered list items. Try this:

## Differences with zx

1. Cross platform shell.
   - Makes more code work on Windows.
   - Allows exporting the shell's environment to the current process.
   - Uses [deno_task_shell](https://github.com/denoland/deno_task_shell)'s parser.
1. Minimal globals or global configuration.
   - Only a default instance of `$`, but it's not mandatory to use this.
1. No custom CLI.
1. Good for application code in addition to use as a shell script replacement.
1. Named after my cat.

Output (GitHub is CommonMark compliant, like comrak, so we can just use it to test):

Differences with zx

  1. Cross platform shell.
    • Makes more code work on Windows.
    • Allows exporting the shell's environment to the current process.
    • Uses deno_task_shell's parser.
  2. Minimal globals or global configuration.
    • Only a default instance of $, but it's not mandatory to use this.
  3. No custom CLI.
  4. Good for application code in addition to use as a shell script replacement.
  5. Named after my cat.

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