英文:
github: how to add links to sections of readme.md
问题
我有一个 GitHub 项目,想要在 README 中添加链接,引用该 README 中的某些部分。我尝试了几种方法,一种是典型的 Markdown,另一种是基于 HTML 的带有锚点的方法。然而,在我的本地浏览器中一切正常,但在 GitHub 上点击链接时不能移动到正确的位置。
这可能是 GitHub 的一个 bug 吗?
以一个具体的示例为例:
https://github.com/Reissner/latex-maven-plugin
英文:
I have a github project and want to add links to the readme
referring to sections on that readme.
I tried several ways, one typical markdown, the other html based with anchor.
Whereas everything works well in my local browser,
on github clicking at the links to not move to the proper position.
Is this maybe a bug in github??
For a concrete example
https://github.com/Reissner/latex-maven-plugin
答案1
得分: 2
I've seen your markdown like:
in [Section 'Features'](#ssFeatures)
## Features <a id='ssFeatures'></a>
You can try to use the following method:
in [Section `Features`](#feature)
## Feature
The "[Section 'Feature']" will be a link to "#Feature"
In addition, you can follow this README which has a lot of "link to section".
If I have answered your question to your satisfaction, then consider accepting the answer.
英文:
I've seen your markdown like:
in [Section 'Features'](#ssFeatures)
## Features <a id='ssFeatures'></a>
Your can try to use the following method:
in [Section `Features`](#feature)
## Feature
The "[Section 'Feature']" will be a link to "#Feature"
In addition, you can follow this README which have a lot of "link to section".
If I have answered your question to your satisfaction, then consider accepting the answer.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论