-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Closed
Labels
L1 - brokenValid usage causes incorrect output OR a crash AND there is no known workaround for the issueValid usage causes incorrect output OR a crash AND there is no known workaround for the issuehelp wantedparser: CommonMark
Description
Marked version: 0.3.17
Markdown flavor: Markdown.pl|CommonMark|GitHub Flavored Markdown
Expectation
Marked can handle HTML attributes without quote like <a href=https://example.com></a> in markdown doc. It should be converted into <p><a href="https://example.com"></a></p>, the same as <a href="https://example.com"></a>.
Result
Converted into broken HTML <p><a href=<a href="https://example.com>">https://example.com></a></a></p>
What was attempted
npm install marked- Put following code to
foo.js - Run
node foo.js
const marked = require('marked');
console.log(marked('<a href=https://example.com></a>'));Call stack & console log
<p><a href=<a href="https://example.com>">https://example.com></a></a></p>
though I expected
<p><a href="https://example.com"></a></p>
Metadata
Metadata
Assignees
Labels
L1 - brokenValid usage causes incorrect output OR a crash AND there is no known workaround for the issueValid usage causes incorrect output OR a crash AND there is no known workaround for the issuehelp wantedparser: CommonMark