Closed iby closed 4 years ago
This is easy! The parser is already doing the right thing, but the renderer in this project needs to be modified.
You just need to modify parserFoundLineBreak
in CMAttributedStringRenderer
(https://github.com/indragiek/CocoaMarkdown/blob/master/CocoaMarkdown/CMAttributedStringRenderer.m#L217) to use a unicode line separator rather than a "\n":
[self appendString:@"\u2028"];
Feel free to make this change and submit a PR. I'm in the middle of a project, but will try and submit a PR for this at some point in the future if you don't.
This was fixed in #35
If I understand correctly cmark does support this, like normal markdown syntax, but attributed string sees this break as a new paragraph. For example, the following markdown:
Should render like this:
But attributed string renders like this:
Have a feeling I'm not the first one wondering about this. Anyone knows anything about this / can comment? If PR is needed, where should I start looking at?