Skip to content

Task lists are rendered even when GFM is disabled #1823

@TheCloudlessSky

Description

@TheCloudlessSky

Marked version:

1.2.3

Describe the bug

Even when gfm: false, task lists are rendered.

To Reproduce

Steps to reproduce the behavior:

  1. Setup options with gfm: false.
  2. Render the following:
Unordered:

- [ ] A
- [ ] B
- [ ] C

Ordered:

1. [ ] A
2. [ ] B
3. [ ] C

A | B
--|--
1 | 2
3 | 4
5 | 6
  1. Confirm that the table is not rendered, but the task list is rendered:

image

Here's some demos:

Expected behavior

Task lists are only an extension of GFM, so I would expect the output to match CommonMark by using the [ ] as part of the rendered text:

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    L1 - brokenValid usage causes incorrect output OR a crash AND there is no known workaround for the issuecategory: listsgood first issueSomething easy to get started withreleased

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions