微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Sphinx 重构文本 - 如果引用是在节标题之前定义的,则对节标题的引用会中断

如何解决Sphinx 重构文本 - 如果引用是在节标题之前定义的,则对节标题的引用会中断

这按预期工作

Section Header
--------------
 
  This is a section header



Refer to section above `Section Header <#section-header>`_

但以下方法不起作用

Refer to section below  `Section Header <#section-header>`_


Section Header 
--------------

   This is a section below

这是一个 sample 来演示它。

解决方法

这里更详细地解释了这个问题以及解决方案

Anchor Test
===========

RST Section headers have a problem with references,refer to the `section below <#section-below>`_ that has the problem. The link does not work.

Section Below
-------------

This is a section below

语法 section below <#section-below>_ 的问题是部分 Section Below 的名称与 external link 语法中使用的标签匹配 section below <#section-below>_

我通过将外部链接中的标签更改为 my section below <#section-below>_

Anchor Test
===========

RST Section headers have a problem with references,refer to the `my section below <#section-below>`_ that has the problem. The link does not work.

Section Below
-------------

This is a section below

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。