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

HTML block working not as expected with \n #680

Closed
leduythuccs opened this issue Jun 12, 2021 · 1 comment
Closed

HTML block working not as expected with \n #680

leduythuccs opened this issue Jun 12, 2021 · 1 comment

Comments

@leduythuccs
Copy link

This

<center>

`a`</center>

will become

<center>
<p><code>a</code></center></p>

Link: https://spec.commonmark.org/dingus/?text=%3Ccenter%3E%0A%0A%60a%60%3C%2Fcenter%3E%0A
image

But if I remove the \n in the second line:

<center>
`a`</center>

It will become

<center>
`a`</center>

Link: https://spec.commonmark.org/dingus/?text=%3Ccenter%3E%0A%60a%60%3C%2Fcenter%3E%0A
image

More cases:
image
image
image

@wooorm
Copy link
Contributor

wooorm commented Jun 12, 2021

This behavior is documented in the spec: https://spec.commonmark.org/0.29/#html-blocks

@jgm jgm closed this as completed Jun 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants