Skip to content

Plain text in HTML that looks like Markdown is not escaped: #402

Open
@joelverhagen

Description

@joelverhagen

Package version: 4.7.0

Input: <span>[a-z]([0-9]){0,4}</span>
Expected: \[a-z\]\(\[0-9\]\)\{0,4\} (or perhaps more minimal if escaping is context aware)
Actual: [a-z]([0-9]){0,4}

I ran into this because I have some regex in HTML plain text that ends up being interpreted as a link.

Minimal repro:

Converter converter = new Converter();
string md = converter.Convert("<span>[a-z]([0-9]){0,4}</span>");
Console.WriteLine(md);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions