title: Asciidoc table for counter values and text references
body: <p>I am creating an asciidoc as described below:</p>
  
  <pre><code>Start of document 
  
  * R{counter:recom}: sentence1 
  ...
  * R{counter:recom}: sentence2
  ...
  * R{counter:recom}: sentence3
  
  End
  </code></pre>
  
  <p>Note: The <code>R{counter:recom}</code> from the asciidoc will be displayed as <code>R1 R2 R3</code> in the resulting document.</p>
  
  <p>I need to create a table at the start of the document which will refer the counters and text form the doc as described below:</p>
  
  <pre><code>Start of document 
  
  |Ref#|text from the document
  |R1|sentence1
  |R2|sentence2
  |R3|sentence3
  
  throughout the doc: 
  
  * R{counter:recom}: sentence1
  ...
  * R{counter:recom}: sentence2
  ...
  * R{counter:recom}: sentence3
  
  End
  </code></pre>
  
  <p>Now, there are 2 unknown things here: </p>
  
  <ol>
  <li><p>How do I refer the counter and sentence part from the asciidoc <code>R1 sentence1</code> in the table together or separately so that, if I change it in the doc it will be changed in the table?</p></li>
  <li><p>How do I refer the counter values in the table so that they work as links to the actual counter value <code>R1</code> in the doc? </p></li>
  </ol>
  
  <p>Not sure there is a readymade construct to achieve this and I haven't figured out how can I achieve it using an <code>anchor</code> or <code>include</code> statement. </p>