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

Falsy rendering code block in a code block #528

Open
AmayaKuro opened this issue Nov 24, 2023 · 2 comments
Open

Falsy rendering code block in a code block #528

AmayaKuro opened this issue Nov 24, 2023 · 2 comments

Comments

@AmayaKuro
Copy link

Description

When rendering a code block with language, it will ignore (```) that has no character between them.
Ex:

Markdown:

image

Display:

image

We can see that (```)markdown will catch nearest (```) but ignore (```)python since nothing is in between them.


Now for code block which has language but does has character in between them:

Markdown:

image

Display:

image

If it has only a character between (```)s , it will still group everything although the second (```) is mean for other code block

Ideas

Like other markdown renderer (e.g. the one used by Github and VSCode), a code block should only catch standalone (```), instead of the next (```) even if they suppose to be used by other block.

@quantizor
Copy link
Owner

quantizor commented Mar 13, 2024

The second set of ``` terminates the prior, you need to escape the inside ones. Thinking about if there's a good way to handle this. When there is a language specified it makes it easier since you know for sure that it's basically a new "opening" but without a language it's ambiguous.

@bogdantimes
Copy link

The second set of ``` terminates the prior, you need to escape the inside ones. Thinking about if there's a good way to handle this. When there is a language specified it makes it easier since you know for sure that it's basically a new "opening" but without a language it's ambiguous.

I have a similar issue, the problem is my fenced code block get’s split because the content of the fenced code block has inline some within it. I wonder if compiler can be configured to properly find fenced code block ending.

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