Skip to content

Move to micromark or other synchronous mdast packages, need table extension, strikethrough extension, and auto-link #4844

@compulim

Description

@compulim

Is your feature request related to a problem?

markdown-it does not fully represent the Markdown tree we want to parse/walk. Also, it's starting showing its age.

Describe the suggestion or request in detail

We want to parse the reference list. However, markdown-it doesn't simply collapse the reference list (#4841) in its tree. However, micromark (backed by mdast) does a better job representing the Markdown.

micromark is part of mdast, which also power remark.

We should consider moving to micromark for maintainability and futureproof.

Describe alternatives you have considered

We cannot use remark because it is async. However, micromark and the mdast-* family of packages looks great.

marked looks pretty outdated.

Currently, out of 4 engines (markdown-it, micromark, remark, marked), all of them return string rather than React or DOM element.

We should also consider moving from sanitize-html to dompurify. Also need to study HTML Sanitizer API in modern browsers.

We should also consider building a new packages for keeping micromark plugins so web devs can reuse them to rebuild their own Markdown engine configurations.

image

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions