Zhiguang Chen

Results 12 comments of Zhiguang Chen

Because the order matters, for example, if you put `SoftLineBreakSyntax()` before `LineBreakSyntax()`, some syntax might not work as expected, or it might lower the performance if you move them around...

I think we can avoid `retread`. We can parse each syntax in a isolated context and never run the same syntax at the same position if the parser returns `null`.

@jonasfj Yes, like you said, we can also do not advance the position in the `TableSyntax._parseRow`, it means we isolate a segment of the source text and parse it independently...

> Ah, so TextParser is a thing for reading a single line. Makes sense. The source to be parsed does not necessarily have to be a single line; it can...

Here is an example of implementing a highlight syntax: ```dart final result = markdownToHtml('==highlight==', inlineSyntaxes: [ DelimiterSyntax('=+', requiresDelimiterRun: true, allowIntraWord: true, tags: [DelimiterTag('mark', 2)]), ]); ``` or ```dart class HighlightSyntax...

The original markers are removed when parsing markdown strings into AST structure, it means there are no markers stored in AST nodes. So maybe it is impossible to reverse with...

I am going to enhance the AST structure in the coming few weeks, the enhanced AST structure will save the markdown markers which will make it possible to reverse AST...

@RichardFevrier Yep, maybe you could create an new issue to describe the requirement in detail?

You are re right. The `DelimiterSyntax` only works when the start and end delimiters are the same. For this syntax, you need to create a syntax that extends from `InlineSyntax`.

But it still maters in some situation, for example 1. **two or more spaces** hard line break, 4 spaces before the line ending. ```markdown a b ``` Output to AST:...