Using links on the GitHub wiki with modified text
I am trying to use internal links to link an index on my wiki page with multiple sections in a document. Here's an example:
* `My index`_
+ Foreword_
+ `Technical details`_
My index
--------
Foreword
~~~~~~~~
Technical details
~~~~~~~~~~~~~~~~~
If I create an HTML page via rest2html I get the correct result. However, the GitHub wiki inserts extra words into links and links do not work. eg:
https://github.com/myaccount/myproject/wiki/Page#wiki-my-index
https://github.com/myaccount/myproject/wiki/Page#wiki-foreword
https://github.com/myaccount/myproject/wiki/Page#wiki-technical-details
I couldn't find any relevant document on the GitHub page, so I got lost.
source to share
It looks like the class ids are missing in the generated divs. Check the source of the page at (none) to see them. I think it should look like this:
<ul>
<li><dl class="first docutils">
<dt><a class="reference internal" href="#my-index">My index</a></dt>
<li><a class="reference internal" href="#foreword">Foreword</a></li>
<li><a class="reference internal" href="#technical-details">Technical details</a></li>
</ul>
<div class="section" id="my-index">
<h1>My index</h1>
</div>
<div class="section" id="foreword">
<h2>Foreword</h2>
</div>
<div class="section" id="technical-details">
<h2>Technical details</h2>
</div>
Edit: user intuited mentions the same issue in the GitHub markup issue
I also noticed this issue with the README.rst files. As well as headers, embedded objects in .rst files, for example. _
some target
, not work. Inline target text is wrapped in a, but does not receive links made for any purpose. Should I point this out as a separate issue?
source to share