-
-
Notifications
You must be signed in to change notification settings - Fork 43
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
Relax disallowing multiple words in code block
/ div
first line?
#214
Comments
Let's see what GFM does with it:
becomes hi and there is no trace of |
Commonmark stores the entire first line as |
I've revised my note above. |
Do you need to split it at all? Just have the whole string be the For You already have block attributes for setting classes, why not just store ithe whole string under a key as well and be done with it 😄 |
(thanks as always for the |
rabid 🐕 Pandoc doesn't store these in the |
😆 🤦♂️ |
Does djot have to do what pandoc does though? |
It seems like Pandoc does not follow commonmark here 🤔 https://spec.commonmark.org/0.30/#info-string |
Pandoc's commonmark and gfm and commonmark_x parsers will ignore the additional content in the case of code blocks. This could be modified to store the whole line in an Pandoc's markdown parser is different. Part of the motivation here is to avoid confusing inline code that happens to start at the beginning of the line and uses three backticks with a code block. |
It feels like, if you have "committed" to writing three backticks at the start of the line, then you are expecting to write a code block.
just not
|
Let's see how GH renders it:
|
Currently
goes to
but
goes to
This feels a little unintuitive to me. Is there a strong reason why this has to be the case?
Could the "additional" first-line content not be stored on the AST nodes?
It would then not be used in the standard HTML renderer,
but could be used by macros
The text was updated successfully, but these errors were encountered: