Skip to content
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

Markdown `*emphasis* inside a paragraph emits incorrect HTML unless it's on the first or last line #1727

Closed
garybernhardt opened this issue Jul 10, 2020 · 4 comments
Labels
category: inline elements L1 - broken Valid usage causes incorrect output OR a crash AND there is no known workaround for the issue

Comments

@garybernhardt
Copy link

Describe the bug
Markdown `emphasis inside a paragraph emits incorrect HTML unless it's on the first or last line.

To Reproduce
Here's what Marked does. Notice that the middle two lines both have one half of an <em> (but different halves!), and in each case one of the *s persists in the output. The first and last lines are unaffected.
Here's what commonmark does, which is correct.

Expected behavior
Markdown with *emphasis* should always turn into an <em></em> tag.

Details
At first I thought that this might be related to #1699, but now that seems unlikely. This bug seems to exist for any *emphasis* in any paragraph.

@UziTech UziTech added category: inline elements L1 - broken Valid usage causes incorrect output OR a crash AND there is no known workaround for the issue labels Jul 11, 2020
@UziTech
Copy link
Member

UziTech commented Jul 11, 2020

looks like this should be fixed by #1686

@calculuschild
Copy link
Contributor

Can confirm this is fixed now.

@UziTech
Copy link
Member

UziTech commented Jul 14, 2020

Should be fixed with marked v1.1.1 🎉

@UziTech UziTech closed this as completed Jul 14, 2020
@garybernhardt
Copy link
Author

Looks good now. Thanks for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: inline elements L1 - broken Valid usage causes incorrect output OR a crash AND there is no known workaround for the issue
Projects
None yet
Development

No branches or pull requests

3 participants