blackfriday icon indicating copy to clipboard operation
blackfriday copied to clipboard

Links: missing information in the AST

Open MichaelMure opened this issue 5 years ago • 0 comments

Considering this example:

This page offers a brief overview of what it's like to use Markdown.
The [syntax page] [s] provides complete, detailed documentation for
every feature, but Markdown should be very easy to pick up simply by
looking at a few examples of it in action. 

  [s]: /projects/markdown/syntax  "Markdown Syntax"
  [d]: /projects/markdown/dingus  "Markdown Dingus"
  [src]: /projects/markdown/basics.text

As far as I can tell, there is no way from the AST to:

  1. know what ref label was used (s, d and src)
  2. know where the list of links is, to render it

Additionally, it seems that node.LinkData.NoteID is never set ? Am I missing someting ?

For some context, I'm writing a terminal renderer, and as the screen space is limited, I want to encourage the ref style links, and actually render them like this.

MichaelMure avatar Jun 08 '19 13:06 MichaelMure