-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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 support mulit blockquotes #4496
Markdown support mulit blockquotes #4496
Conversation
I don't think the change is correct. In Dingus I can see the newlines are preserved, and this happens everywhere in Markdown. The current behavior is fine. What does this fix for you? Is it rendered wrong somewhere? |
@asterite The newlines are left in the generated HTML but by default HTML doesn't respect newlines. So this change is incorrect in terms of generated HTML but correct in visual output (but only in the typical case) I think. |
If use Dingus test, this code is broken style: > Hello
> World In crystal: <blockquote>Hello</blockquote>\n\n<blockquote>World</blockquote> but in Dingus: <blockquote>
<p>Hello</p>
<p>World</p>
</blockquote> |
Hm, I'm not sure Dingus is right about that last example. In GitHub I see they generate two blockquotes. I guess we should implement some standard markdown and use an external spec, but there seems to be many standards. I think it would be best to move Markdown inside the Crystal namespace and let it be private and only be used in the doc generation: markdown can be provided by shards. |
Why not use CommonMark as the default standard spec? For now, it is a tool for write with most of users or developers. I think it is better than current version. But move it out is also a solution. 😃 |
The commonmark spec is pretty comprehensive regarding quotes. Ideally we would extract all the test cases from commonmark and make that our test suite. Edit: looks like the commonmark repo has a tool which extracts test cases from the spec. |
Sure, using commonmark in the std is also another very good option. That way we can have specs that match a better spec than the one in the official markdown page. |
close for now |
fix broken blockquote style with multi blockquote:
before:
after: