-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GFM underscore parsing is broken #491
Comments
the behaviour is not consistent though. In some of our markdown files (with more code blocks and heavier markup) this behaviour is shown, and in others (usually lighter markup) it works as expected. I'll update here when I know more |
Allright, I've finally narrowed a reproducable setup.
Should result in this: But instead it results in this: Reproduce steps
Lorem_ipsum dolor sit amet, __consectetur adipisicing__ elit. Voluptatem a __ea voluptas nihil__ error modi.
Lorem_ipsum dolor sit amet, **consectetur adipisicing** elit. Voluptatem a **ea voluptas nihil** error modi.
marked -i input.md -o output.html
<p>Lorem<em>ipsum dolor sit amet, <strong>consectetur adipisicing</strong> elit. Voluptatem a <em>_ea voluptas nihil</em></em> error modi.</p>
<p>Lorem_ipsum dolor sit amet, <strong>consectetur adipisicing</strong> elit. Voluptatem a <strong>ea voluptas nihil</strong> error modi.</p> Cheers |
This one also produces wrong output:
out
|
I have one too: while this is correct $ marked
{{some_test_thing}}
<p>{{some_test_thing}}</p> this is not $ marked
{{some_test_thing}} _another_ thing
<p>{{some<em>test_thing}} _another</em> thing</p> |
becomes
And it shouldn't, according to https://help.github.com/articles/github-flavored-markdown#multiple-underscores-in-words. The result should be the same as the input:
Cheers,
JD
The text was updated successfully, but these errors were encountered: