Skip to content

Don't trim non-ASCII whitespaces #1067

@tats-u

Description

@tats-u

CommonMark doesn't require implementations to remove non-ASCII white spaces (just says "space", which means U+0020).
However, markdown-it removes them.
This is due to the fact markdown-it and prior CommonMark.js uses .tirm() to remove leading/trailing space-like characters, including non-ASCII ones.

The specification of .trim(): https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/trim

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions